You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* @dev Event emitted when a user updates their public key.
@@ -65,15 +67,15 @@ interface IERC7627 {
65
67
* @param _publicKey The public key of the user.
66
68
* @param _algorithm The algorithm used for the public key.
67
69
*/
68
-
function updatePublicKey(bytes memory _publicKey, PublicKeyAlgorithm _algorithm) external;
70
+
function updatePublicKey(bytes calldata _publicKey, PublicKeyAlgorithm _algorithm) external;
69
71
70
72
/**
71
73
* @dev Function to send an encrypted message from one user to another.
72
74
* @param _to The address of the recipient.
73
75
* @param _sessionId The session ID of the message.
74
76
* @param _encryptedMessage The encrypted message.
75
77
*/
76
-
function sendMessage(address _to, string memory _sessionId, bytes memory _encryptedMessage) external;
78
+
function sendMessage(address _to, bytes32 _sessionId, bytes calldata _encryptedMessage) external;
77
79
78
80
/**
79
81
* @dev Function to retrieve a user's public key and algorithm.
@@ -87,7 +89,7 @@ interface IERC7627 {
87
89
88
90
## Rationale
89
91
90
-
Traditional messaging lacks security and transparency for blockchain communication. The choice of asymmetric encryption ensures the confidentiality and integrity of messages, which is why we opted for this encryption method. Providing a unified interface enables easy integration of encrypted communication into smart contracts, thereby fostering innovation. Encrypted messaging guarantees adherence to best practices in data security. The interface supports various encryption methods, enhancing adaptability. Event tracking enhances the observability and auditability of the contract, aiding compliance efforts. Standardization promotes interoperability, facilitating seamless communication across platforms.
92
+
Traditional messaging lacks security and transparency for blockchain communication. The choice of asymmetric encryption ensures the confidentiality and integrity of messages, which is why we opted for this encryption method. Providing a unified interface enables easy integration of encrypted communication into smart contracts, thereby fostering innovation. Encrypted messaging guarantees adherence to best practices in data security. Due to security reasons, public keys need to be regularly updated, hence we have added a feature that allows users to autonomously update their public keys. The interface supports various encryption methods, enhancing adaptability. Event tracking enhances the observability and auditability of the contract, aiding compliance efforts. Standardization promotes interoperability, facilitating seamless communication across platforms.
1. Utilization of Latest Secure Encryption Algorithms: When selecting encryption algorithms, it is essential to stay informed about the latest security news and recommendations. Avoid using asymmetric encryption algorithms with known vulnerabilities or those not recommended to ensure the confidentiality and integrity of messages. Regularly update encryption algorithms to address evolving security threats.
135
+
### 1. Utilization of Latest Secure Encryption Algorithms:
136
+
When selecting encryption algorithms, it is essential to stay informed about the latest security news and recommendations. Avoid using asymmetric encryption algorithms with known vulnerabilities or those not recommended to ensure the confidentiality and integrity of messages. Regularly update encryption algorithms to address evolving security threats.
134
137
135
-
2. Strict Encryption Using Public Keys for Message Content: To maintain message confidentiality, the content of sent messages must be strictly encrypted using the recipient's public key. Any plaintext information transmitted could lead to information leakage and security risks. Encrypt message content at all times during transmission and storage to prevent unauthorized access to sensitive information.
138
+
### 2. Strict Encryption Using Public Keys for Message Content:
139
+
To maintain message confidentiality, the content of sent messages must be strictly encrypted using the recipient's public key. Any plaintext information transmitted could lead to information leakage and security risks. Encrypt message content at all times during transmission and storage to prevent unauthorized access to sensitive information.
136
140
137
-
3. Key Management and Protection: Robust key management and protection measures are necessary for both user public and private keys. Ensure secure storage and transmission of keys to prevent leakage and tampering. Employ multi-factor authentication and key rotation strategies to enhance key security and regularly assess key management processes to mitigate potential security risks.
141
+
### 3. Key Management and Protection:
142
+
Robust key management and protection measures are necessary for both user public and private keys. Ensure secure storage and transmission of keys to prevent leakage and tampering. Employ multi-factor authentication and key rotation strategies to enhance key security and regularly assess key management processes to mitigate potential security risks.
138
143
139
-
4. Auditing and Monitoring: Implement auditing and monitoring mechanisms to track message sending and receiving, as well as key usage. Promptly identify anomalous activities and potential security threats and take appropriate response measures. Record critical operations and events for security incident investigation and traceability purposes.
144
+
### 4. Auditing and Monitoring:
145
+
Implement auditing and monitoring mechanisms to track message sending and receiving, as well as key usage. Promptly identify anomalous activities and potential security threats and take appropriate response measures. Record critical operations and events for security incident investigation and traceability purposes.
0 commit comments