C# Class RSA_PM_Client.Client

Mostra file Open project: RSA-PM/RSA-PM Class Usage Examples

Public Methods

Method Description
Client ( string server_addr, Int16 server_port, string proxy_addr, Int16 proxy_port, RSAParameters server_pubkey ) : System
DecodeMessage2 ( Stream sr2, RSAParameters rsaprv, byte mypub ) : Message
GetMessage ( byte prvkey, byte pubkey, Action store ) : int
RegisterPublicKey ( byte prvkey, byte pubkey ) : void
SendMessage ( byte recipient_pubkey, byte replyTo, string txt, byte prvkey, byte pubkey ) : byte[]
UnregisterPublicKey ( byte prvkey, byte pubkey ) : void

Private Methods

Method Description
DecodeMessage ( byte aesbuf, byte aeskey, byte aesIV, RSAParameters rsap, byte mypub ) : Message
EncodeMessage ( byte recipient_pubkey, byte msgid, byte replyTo, string txt, byte prvkey, byte pubkey, byte &aes_key, byte &aes_iv ) : byte[]
SendPublicKey ( byte pubkey ) : void

Method Details

Client() public method

public Client ( string server_addr, Int16 server_port, string proxy_addr, Int16 proxy_port, RSAParameters server_pubkey ) : System
server_addr string
server_port System.Int16
proxy_addr string
proxy_port System.Int16
server_pubkey System.Security.Cryptography.RSAParameters
return System

DecodeMessage2() public static method

public static DecodeMessage2 ( Stream sr2, RSAParameters rsaprv, byte mypub ) : Message
sr2 Stream
rsaprv System.Security.Cryptography.RSAParameters
mypub byte
return Message

GetMessage() public method

public GetMessage ( byte prvkey, byte pubkey, Action store ) : int
prvkey byte
pubkey byte
store Action
return int

RegisterPublicKey() public method

public RegisterPublicKey ( byte prvkey, byte pubkey ) : void
prvkey byte
pubkey byte
return void

SendMessage() public method

public SendMessage ( byte recipient_pubkey, byte replyTo, string txt, byte prvkey, byte pubkey ) : byte[]
recipient_pubkey byte
replyTo byte
txt string
prvkey byte
pubkey byte
return byte[]

UnregisterPublicKey() public method

public UnregisterPublicKey ( byte prvkey, byte pubkey ) : void
prvkey byte
pubkey byte
return void