Did I find the right examples for you? yes no

All Samples(8)  |  Call(4)  |  Derive(0)  |  Import(4)

src/g/a/gaffer-0.5.2/gaffer/httpclient/websocket.py   gaffer(Download)
from ..message import (Message, decode_frame, FRAME_ERROR_TYPE,
        FRAME_RESPONSE_TYPE, FRAME_MESSAGE_TYPE)
from ..util import urlparse, ord_
 
# The initial handshake over HTTP.
 
    # Clients must apply a 32-bit mask to all data sent.
    mask = [ord_(c) for c in os.urandom(4)]
    frame += struct.pack('!BBBB', *mask)
    # Mask each byte of data using a byte from the mask.
    msg = [ord_(c) ^ mask[i % 4] for i, c in enumerate(data)]

src/g/a/gaffer-HEAD/gaffer/httpclient/websocket.py   gaffer(Download)
from ..message import (Message, decode_frame, FRAME_ERROR_TYPE,
        FRAME_RESPONSE_TYPE, FRAME_MESSAGE_TYPE)
from ..util import urlparse, ord_
 
# The initial handshake over HTTP.
 
    # Clients must apply a 32-bit mask to all data sent.
    mask = [ord_(c) for c in os.urandom(4)]
    frame += struct.pack('!BBBB', *mask)
    # Mask each byte of data using a byte from the mask.
    msg = [ord_(c) ^ mask[i % 4] for i, c in enumerate(data)]

src/g/a/gaffer-0.5.2/gaffer/gafferd/users.py   gaffer(Download)
import uuid
 
from ..util import bytestring, ord_
from .pbkdf2 import pbkdf2_hex
from .util import load_backend

src/g/a/gaffer-HEAD/gaffer/gafferd/users.py   gaffer(Download)
import uuid
 
from ..util import bytestring, ord_
from .pbkdf2 import pbkdf2_hex
from .util import load_backend