Example #1
0
 def __init__(self, optional = False):
     CompositeType.__init__(self, optional = optional)
     self.code = UInt8()
     self.flag = UInt8(0)
     #always 8
     self.len = UInt16Le(0x0008, constant = True)
     self.selectedProtocol = UInt32Le(conditional = lambda: self.code == NegociationType.TYPE_RDP_NEG_RSP)
     self.failureCode = UInt32Le(conditional = lambda: self.code == NegociationType.TYPE_RDP_NEG_FAILURE)
Example #2
0
 def __init__(self, name="", options=UInt32Le()):
     CompositeType.__init__(self)
     #name of channel
     self.name = String(name[0:8] + "\x00" * (8 - len(name)),
                        readLen=UInt8(8))
     #unknown
     self.options = options
Example #3
0
def writeClientNetworkData(channels):
    '''
    write network packet whith channels infos
    @param channels: list of ClientRequestedChannel
    @return: gcc network packet
    '''
    if len(channels) == 0:
        return ()
    return (ClientToServerMessage.CS_NET,
            UInt16Le(len(channels) * sizeof(ClientRequestedChannel()) + 8),
            UInt32Le(len(channels)), tuple(channels))
Example #4
0
 def __init__(self):
     CompositeType.__init__(self)
     self.rdpVersion = Version.RDP_VERSION_5_PLUS
     self.desktopWidth = UInt16Le(1280)
     self.desktopHeight = UInt16Le(1024)
     self.colorDepth = ColorDepth.RNS_UD_COLOR_8BPP
     self.sasSequence = Sequence.RNS_UD_SAS_DEL
     self.kbdLayout = KeyboardLayout.FRENCH
     self.clientBuild = UInt32Le(3790)
     self.clientName = UniString("rdpy" + "\x00" * 11, readLen=UInt8(30))
     self.keyboardType = KeyboardType.IBM_101_102_KEYS
     self.keyboardSubType = UInt32Le(0)
     self.keyboardFnKeys = UInt32Le(12)
     self.imeFileName = String("\x00" * 64, readLen=UInt8(64))
     self.postBeta2ColorDepth = ColorDepth.RNS_UD_COLOR_8BPP
     self.clientProductId = UInt16Le(1)
     self.serialNumber = UInt32Le(0)
     self.highColorDepth = HighColor.HIGH_COLOR_24BPP
     self.supportedColorDepths = Support.RNS_UD_24BPP_SUPPORT | Support.RNS_UD_16BPP_SUPPORT | Support.RNS_UD_15BPP_SUPPORT
     self.earlyCapabilityFlags = CapabilityFlags.RNS_UD_CS_SUPPORT_ERRINFO_PDU
     self.clientDigProductId = String("\x00" * 64, readLen=UInt8(64))
     self.connectionType = UInt8()
     self.pad1octet = UInt8()
     self.serverSelectedProtocol = UInt32Le()
Example #5
0
File: lic.py Project: anees042/rdpy
 def __init__(self, conditional=lambda: True):
     CompositeType.__init__(self, conditional=conditional)
     self.dwErrorCode = UInt32Le()
     self.dwStateTransition = UInt32Le()
     self.blob = LicenceBinaryBlob()
Example #6
0
 def __init__(self):
     CompositeType.__init__(self)
     self.encryptionMethod = UInt32Le()
     self.encryptionLevel = UInt32Le()
Example #7
0
 def __init__(self):
     CompositeType.__init__(self)
     self.encryptionMethods = UInt32Le()
     self.extEncryptionMethods = UInt32Le()
Example #8
0
 def __init__(self):
     CompositeType.__init__(self)
     self.rdpVersion = Version.RDP_VERSION_5_PLUS
     self.clientRequestedProtocol = UInt32Le()