예제 #1
0
    def read(data: BytesIO, *args: Any) -> "PQInnerDataTempDc":
        # No flags

        pq = Bytes.read(data)

        p = Bytes.read(data)

        q = Bytes.read(data)

        nonce = Int128.read(data)

        server_nonce = Int128.read(data)

        new_nonce = Int256.read(data)

        dc = Int.read(data)

        expires_in = Int.read(data)

        return PQInnerDataTempDc(pq=pq,
                                 p=p,
                                 q=q,
                                 nonce=nonce,
                                 server_nonce=server_nonce,
                                 new_nonce=new_nonce,
                                 dc=dc,
                                 expires_in=expires_in)
예제 #2
0
 def read(data: BytesIO, *args: Any) -> "DhGenRetry":
     # No flags
     
     nonce = Int128.read(data)
     
     server_nonce = Int128.read(data)
     
     new_nonce_hash2 = Int128.read(data)
     
     return DhGenRetry(nonce=nonce, server_nonce=server_nonce, new_nonce_hash2=new_nonce_hash2)
예제 #3
0
 def read(data: BytesIO, *args: Any) -> "DhGenOk":
     # No flags
     
     nonce = Int128.read(data)
     
     server_nonce = Int128.read(data)
     
     new_nonce_hash1 = Int128.read(data)
     
     return DhGenOk(nonce=nonce, server_nonce=server_nonce, new_nonce_hash1=new_nonce_hash1)
 def read(data: BytesIO, *args: Any) -> "SetClientDHParams":
     # No flags
     
     nonce = Int128.read(data)
     
     server_nonce = Int128.read(data)
     
     encrypted_data = Bytes.read(data)
     
     return SetClientDHParams(nonce=nonce, server_nonce=server_nonce, encrypted_data=encrypted_data)
    def read(data: BytesIO, *args: Any) -> "ServerDHParamsFail":
        # No flags

        nonce = Int128.read(data)

        server_nonce = Int128.read(data)

        new_nonce_hash = Int128.read(data)

        return ServerDHParamsFail(nonce=nonce, server_nonce=server_nonce, new_nonce_hash=new_nonce_hash)
예제 #6
0
 def read(data: BytesIO, *args: Any) -> "ClientDHInnerData":
     # No flags
     
     nonce = Int128.read(data)
     
     server_nonce = Int128.read(data)
     
     retry_id = Long.read(data)
     
     g_b = Bytes.read(data)
     
     return ClientDHInnerData(nonce=nonce, server_nonce=server_nonce, retry_id=retry_id, g_b=g_b)
    def read(data: BytesIO, *args: Any) -> "ServerDHParamsOk":
        # No flags

        nonce = Int128.read(data)

        server_nonce = Int128.read(data)

        encrypted_answer = Bytes.read(data)

        return ServerDHParamsOk(nonce=nonce,
                                server_nonce=server_nonce,
                                encrypted_answer=encrypted_answer)
예제 #8
0
 def read(data: BytesIO, *args: Any) -> "ResPQ":
     # No flags
     
     nonce = Int128.read(data)
     
     server_nonce = Int128.read(data)
     
     pq = Bytes.read(data)
     
     server_public_key_fingerprints = TLObject.read(data, Long)
     
     return ResPQ(nonce=nonce, server_nonce=server_nonce, pq=pq, server_public_key_fingerprints=server_public_key_fingerprints)
예제 #9
0
 def read(data: BytesIO, *args: Any) -> "ReqDHParams":
     # No flags
     
     nonce = Int128.read(data)
     
     server_nonce = Int128.read(data)
     
     p = Bytes.read(data)
     
     q = Bytes.read(data)
     
     public_key_fingerprint = Long.read(data)
     
     encrypted_data = Bytes.read(data)
     
     return ReqDHParams(nonce=nonce, server_nonce=server_nonce, p=p, q=q, public_key_fingerprint=public_key_fingerprint, encrypted_data=encrypted_data)
예제 #10
0
 def read(data: BytesIO, *args: Any) -> "ServerDHInnerData":
     # No flags
     
     nonce = Int128.read(data)
     
     server_nonce = Int128.read(data)
     
     g = Int.read(data)
     
     dh_prime = Bytes.read(data)
     
     g_a = Bytes.read(data)
     
     server_time = Int.read(data)
     
     return ServerDHInnerData(nonce=nonce, server_nonce=server_nonce, g=g, dh_prime=dh_prime, g_a=g_a, server_time=server_time)
예제 #11
0
    def read(data: BytesIO, *args: Any) -> "PQInnerData":
        # No flags

        pq = Bytes.read(data)

        p = Bytes.read(data)

        q = Bytes.read(data)

        nonce = Int128.read(data)

        server_nonce = Int128.read(data)

        new_nonce = Int256.read(data)

        return PQInnerData(pq=pq,
                           p=p,
                           q=q,
                           nonce=nonce,
                           server_nonce=server_nonce,
                           new_nonce=new_nonce)
예제 #12
0
    def read(data: BytesIO, *args: Any) -> "ReqPqMulti":
        # No flags

        nonce = Int128.read(data)

        return ReqPqMulti(nonce=nonce)