Question: Write a c++ or c client server program that uses rsa encryption/decryption algorithm to communicate to each other through a third(middle) party(class) that acts as
Write a c++ or c
client server program that uses rsa encryption/decryption algorithm to communicate to each other through a third(middle) party(class) that acts as the key manager between the client and server ( sens the client or server each others public key when they reques it) here is a picture tp help you understand
Assumptions All principals (clients and brokers) know the Key Manager's IP address and port number All clients know the IP address and port number of all brokers Clients requests to buy/sell stocks do not need to identify which stock. Assume a default stock. (Students may add this field in the struct definition, but it will increase the size of the message that need to be encrypted Client Key Manager Broker (1) Register(Client_ID, K(Client, pub)) (1) Register(Broker_ID, K(Broker, pub)) (2) Request_key(Broker) (3) Key(Broker, pub) (4) P Buy(Clien t ID, Trans_ID, Num_Stocks) C Encrypt[P, K(Broker, pub)] (5) Decrypt[C, K(Broker, priv)] P Confirm(Client ID, Trans ID, Num_Stocks) C Encrypt[P, K(Client, pub)] (6) Decrypt[C, K(Client, priv)] P Verify(Client ID, Trans ID, Num Stocks) C Encrypt[P, K(Client, priv)] (6) Request_key(Client) (7) Key(Client, pub) (8) Decrypt[C, K(Client, pub)] P Done(Client ID, Trans ID Num_Stocks) CEncrypt[P, K(Broker, priv)] (9) Decrypt[C, K(Broker, pub)] Assumptions All principals (clients and brokers) know the Key Manager's IP address and port number All clients know the IP address and port number of all brokers Clients requests to buy/sell stocks do not need to identify which stock. Assume a default stock. (Students may add this field in the struct definition, but it will increase the size of the message that need to be encrypted Client Key Manager Broker (1) Register(Client_ID, K(Client, pub)) (1) Register(Broker_ID, K(Broker, pub)) (2) Request_key(Broker) (3) Key(Broker, pub) (4) P Buy(Clien t ID, Trans_ID, Num_Stocks) C Encrypt[P, K(Broker, pub)] (5) Decrypt[C, K(Broker, priv)] P Confirm(Client ID, Trans ID, Num_Stocks) C Encrypt[P, K(Client, pub)] (6) Decrypt[C, K(Client, priv)] P Verify(Client ID, Trans ID, Num Stocks) C Encrypt[P, K(Client, priv)] (6) Request_key(Client) (7) Key(Client, pub) (8) Decrypt[C, K(Client, pub)] P Done(Client ID, Trans ID Num_Stocks) CEncrypt[P, K(Broker, priv)] (9) Decrypt[C, K(Broker, pub)]
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
