C client server program using UDP Sockets using below structure. In c/c++, or just some methods to send and save public key from client and broker to key manager class then have key manager send to other when requested. Like in picture
Need a C++ program client/server(broker in this case) program that uses UDP sockets to communicate to each other using a third party(class) key manager for RSA encryption 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 (1) Register(Client ID, K(Client, pub)) Key Manager Broker (1) Reg ster(Broker ID, K(Broker, pub)) (2) Request key(Broker) (3) Key(Broker, pub) 4) P - Buy Clien t ID, Trans ID Num Stocks) C-EncryptP, K(Broker, pub) 5) Decrypt C, K(Broker, priv)] P Confirm(Client ID, Trans ID Num _Stocks) C " Encrypt(P, K(Client, pub)) (6) DecryptC, K(Client, priv)l P- Verify Client ID, Trans ID, Num Stocks) C Encrypt[P, K(Client, priv) (6) Request key Client) (7) KeylClient, pub) (8) DecryptC, KClient, pub)] P Done(Client ID, Trans ID Num Stocks) Encrypt(P, K(Broker, priv)l (9) Decrypt[C, K(Broker, pub)) Need a C++ program client/server(broker in this case) program that uses UDP sockets to communicate to each other using a third party(class) key manager for RSA encryption 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 (1) Register(Client ID, K(Client, pub)) Key Manager Broker (1) Reg ster(Broker ID, K(Broker, pub)) (2) Request key(Broker) (3) Key(Broker, pub) 4) P - Buy Clien t ID, Trans ID Num Stocks) C-EncryptP, K(Broker, pub) 5) Decrypt C, K(Broker, priv)] P Confirm(Client ID, Trans ID Num _Stocks) C " Encrypt(P, K(Client, pub)) (6) DecryptC, K(Client, priv)l P- Verify Client ID, Trans ID, Num Stocks) C Encrypt[P, K(Client, priv) (6) Request key Client) (7) KeylClient, pub) (8) DecryptC, KClient, pub)] P Done(Client ID, Trans ID Num Stocks) Encrypt(P, K(Broker, priv)l (9) Decrypt[C, K(Broker, pub))