✘✘ GRAYBYTE WORDPRESS FILE MANAGER ✘✘

​🇳​​🇦​​🇲​​🇪♯➤ beluga.o2switch.net ​🇻​♯➤ 4.18.0-553.123.2.lve.el8.x86_64 #1 SMP 🇾​♯➤ 2026

𝗛𝗢𝗠𝗘 𝗜𝗗 ♯➤ 185.154.139.77 ♯➤ 𝗔𝗗𝗠𝗜𝗡 𝗜𝗗 216.73.216.84
𝗢𝗣𝗧𝗜𝗢𝗡𝗦 ♯ CRL ♯➤ 𝗢𝗞 ┃ WGT ♯➤ 𝗢𝗞 ┃ SDO ♯➤ 𝗢𝗙𝗙 ┃ PKEX ♯➤ 𝗢𝗙𝗙
𝗗𝗘𝗔𝗖𝗧𝗜𝗩𝗔𝗧𝗘𝗗 ♯➤ 𝗔𝗟𝗟 𝗪𝗢𝗥𝗞𝗜𝗡𝗚....

𝗛𝗢𝗠𝗘
𝗖𝗨𝗥𝗥𝗘𝗡𝗧 𝗙𝗜𝗟𝗘 : /opt/alt/python27/lib/python2.7/site-packages/webob//client.py
import errno
import sys
import re
try:
    import httplib
except ImportError: # pragma: no cover
    import http.client as httplib
from webob.compat import url_quote
import socket
from webob import exc
from webob.compat import PY3


__all__ = ['send_request_app', 'SendRequest']

class SendRequest:
    """
    Sends the request, as described by the environ, over actual HTTP.
    All controls about how it is sent are contained in the request
    environ itself.

    This connects to the server given in SERVER_NAME:SERVER_PORT, and
    sends the Host header in HTTP_HOST -- they do not have to match.
    You can send requests to servers despite what DNS says.

    Set ``environ['webob.client.timeout'] = 10`` to set the timeout on
    the request (to, for example, 10 seconds).

    Does not add X-Forwarded-For or other standard headers

    If you use ``send_request_app`` then simple ``httplib``
    connections will be used.
    """

    def __init__(self, HTTPConnection=httplib.HTTPConnection,
                 HTTPSConnection=httplib.HTTPSConnection):
        self.HTTPConnection = HTTPConnection
        self.HTTPSConnection = HTTPSConnection

    def __call__(self, environ, start_response):
        scheme = environ['wsgi.url_scheme']
        if scheme == 'http':
            ConnClass = self.HTTPConnection
        elif scheme == 'https':
            ConnClass = self.HTTPSConnection
        else:
            raise ValueError(
                "Unknown scheme: %r" % scheme)
        if 'SERVER_NAME' not in environ:
            host = environ.get('HTTP_HOST')
            if not host:
                raise ValueError(
                    "environ contains neither SERVER_NAME nor HTTP_HOST")
            if ':' in host:
                host, port = host.split(':', 1)
            else:
                if scheme == 'http':
                    port = '80'
                else:
                    port = '443'
            environ['SERVER_NAME'] = host
            environ['SERVER_PORT'] = port
        kw = {}
        if ('webob.client.timeout' in environ and
            self._timeout_supported(ConnClass) ):
            kw['timeout'] = environ['webob.client.timeout']
        conn = ConnClass('%(SERVER_NAME)s:%(SERVER_PORT)s' % environ, **kw)
        headers = {}
        for key, value in environ.items():
            if key.startswith('HTTP_'):
                key = key[5:].replace('_', '-').title()
                headers[key] = value
        path = (url_quote(environ.get('SCRIPT_NAME', ''))
                + url_quote(environ.get('PATH_INFO', '')))
        if environ.get('QUERY_STRING'):
            path += '?' + environ['QUERY_STRING']
        try:
            content_length = int(environ.get('CONTENT_LENGTH', '0'))
        except ValueError:
            content_length = 0
        ## FIXME: there is no streaming of the body, and that might be useful
        ## in some cases
        if content_length:
            body = environ['wsgi.input'].read(content_length)
        else:
            body = ''
        headers['Content-Length'] = content_length
        if environ.get('CONTENT_TYPE'):
            headers['Content-Type'] = environ['CONTENT_TYPE']
        if not path.startswith("/"):
            path = "/" + path
        try:
            conn.request(environ['REQUEST_METHOD'],
                         path, body, headers)
            res = conn.getresponse()
        except socket.timeout:
            resp = exc.HTTPGatewayTimeout()
            return resp(environ, start_response)
        except (socket.error, socket.gaierror) as e:
            if ((isinstance(e, socket.error) and e.args[0] == -2) or
                (isinstance(e, socket.gaierror) and e.args[0] == 8)):
                # Name or service not known
                resp = exc.HTTPBadGateway(
                    "Name or service not known (bad domain name: %s)"
                    % environ['SERVER_NAME'])
                return resp(environ, start_response)
            elif e.args[0] in _e_refused: # pragma: no cover
                # Connection refused
                resp = exc.HTTPBadGateway("Connection refused")
                return resp(environ, start_response)
            raise
        headers_out = self.parse_headers(res.msg)
        status = '%s %s' % (res.status, res.reason)
        start_response(status, headers_out)
        length = res.getheader('content-length')
        # FIXME: This shouldn't really read in all the content at once
        if length is not None:
            body = res.read(int(length))
        else:
            body = res.read()
        conn.close()
        return [body]

    # Remove these headers from response (specify lower case header
    # names):
    filtered_headers = (
        'transfer-encoding',
    )

    MULTILINE_RE = re.compile(r'\r?\n\s*')

    def parse_headers(self, message):
        """
        Turn a Message object into a list of WSGI-style headers.
        """
        headers_out = []
        if PY3:  # pragma: no cover
            headers = message._headers
        else:  # pragma: no cover
            headers = message.headers
        for full_header in headers:
            if not full_header: # pragma: no cover
                # Shouldn't happen, but we'll just ignore
                continue
            if full_header[0].isspace():  # pragma: no cover
                # Continuation line, add to the last header
                if not headers_out:
                    raise ValueError(
                        "First header starts with a space (%r)" % full_header)
                last_header, last_value = headers_out.pop()
                value = last_value + ', ' + full_header.strip()
                headers_out.append((last_header, value))
                continue
            if isinstance(full_header, tuple):  # pragma: no cover
                header, value = full_header
            else:  # pragma: no cover
                try:
                    header, value = full_header.split(':', 1)
                except:
                    raise ValueError("Invalid header: %r" % (full_header,))
            value = value.strip()
            if '\n' in value or '\r\n' in value:  # pragma: no cover
                # Python 3 has multiline values for continuations, Python 2
                # has two items in headers
                value = self.MULTILINE_RE.sub(', ', value)
            if header.lower() not in self.filtered_headers:
                headers_out.append((header, value))
        return headers_out

    def _timeout_supported(self, ConnClass):
        if sys.version_info < (2, 7) and ConnClass in (
            httplib.HTTPConnection, httplib.HTTPSConnection): # pragma: no cover
            return False
        return True


send_request_app = SendRequest()

_e_refused = (errno.ECONNREFUSED,)
if hasattr(errno, 'ENODATA'): # pragma: no cover
    _e_refused += (errno.ENODATA,)



Current_dir [ 𝗡𝗢𝗧 𝗪𝗥𝗜𝗧𝗘𝗔𝗕𝗟𝗘 ] Document_root [ 𝗪𝗥𝗜𝗧𝗘𝗔𝗕𝗟𝗘 ]


[ Back ]
𝗡𝗔𝗠𝗘
𝗦𝗜𝗭𝗘
𝗟𝗔𝗦𝗧 𝗧𝗢𝗨𝗖𝗛
𝗨𝗦𝗘𝗥
𝗦𝗧𝗔𝗧𝗨𝗦
𝗙𝗨𝗡𝗖𝗧𝗜𝗢𝗡𝗦
..
--
8 Jan 2025 10.42 AM
root / linksafe
0755
__init__.py
0.324 KB
11 Oct 2012 6.05 PM
root / linksafe
0644
__init__.pyc
0.572 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
acceptparse.py
9.966 KB
11 Oct 2012 5.15 PM
root / linksafe
0644
acceptparse.pyc
14.157 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
byterange.py
4.627 KB
11 Oct 2012 5.15 PM
root / linksafe
0644
byterange.pyc
5.808 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
cachecontrol.py
6.451 KB
13 Oct 2011 5.46 PM
root / linksafe
0644
cachecontrol.pyc
8.793 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
client.py
6.744 KB
11 Oct 2012 5.15 PM
root / linksafe
0644
client.pyc
5.52 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
compat.py
3.419 KB
11 Oct 2012 5.15 PM
root / linksafe
0644
compat.pyc
4.789 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
cookies.py
10.619 KB
18 Feb 2012 3.42 PM
root / linksafe
0644
cookies.pyc
16.508 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
datetime_utils.py
2.493 KB
11 Oct 2012 5.15 PM
root / linksafe
0644
datetime_utils.pyc
3.821 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
dec.py
9.945 KB
31 Jan 2012 4.47 PM
root / linksafe
0644
dec.pyc
11.158 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
descriptors.py
8.809 KB
31 Jan 2012 4.47 PM
root / linksafe
0644
descriptors.pyc
13.646 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
etag.py
4.425 KB
31 Jan 2012 4.47 PM
root / linksafe
0644
etag.pyc
8.508 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
exc.py
34.633 KB
11 Oct 2012 5.15 PM
root / linksafe
0644
exc.pyc
41.585 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
headers.py
4.147 KB
29 Jan 2012 1.42 AM
root / linksafe
0644
headers.pyc
6.719 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
multidict.py
13.768 KB
11 Oct 2012 6.05 PM
root / linksafe
0644
multidict.pyc
20.381 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
request.py
57.725 KB
11 Oct 2012 5.15 PM
root / linksafe
0644
request.pyc
56.735 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
response.py
41.508 KB
11 Oct 2012 5.15 PM
root / linksafe
0644
response.pyc
40.974 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
static.py
5.51 KB
11 Oct 2012 5.15 PM
root / linksafe
0644
static.pyc
6.042 KB
21 Oct 2019 5.04 PM
root / linksafe
0644
util.py
3.521 KB
25 Jan 2012 8.13 PM
root / linksafe
0644
util.pyc
3.982 KB
21 Oct 2019 5.04 PM
root / linksafe
0644

✘✘ GRAYBYTE WORDPRESS FILE MANAGER @ 2026 CONTACT ME ✘✘
Static GIF Static GIF