- Latest Versions
| Name | Version | Description |
|---|---|---|
| Ming Ke Ming (名可名) | Decentralized User Identity Authentication | |
| Dao Ke Dao (道可道) | Universal Message Module | |
| DIMP (去中心化通讯协议) | Decentralized Instant Messaging Protocol |
- Data Coding
- Base-58
- Base-64
- Hex
- UTF-8
- JsON
- PNF (Portable Network File)
- TED (Transportable Encoded Data)
- Digest Digest
- SHA-256
- Keccak-256
- RipeMD-160
- Cryptography
- AES-256 (AES/CBC/PKCS7Padding)
- RSA-1024 (RSA/ECB/PKCS1Padding), (SHA256withRSA)
- ECC (Secp256k1)
from typing import Optional
from dimp import Base64
from dimap import PluginLoader
from dimap import Base64Coder
class CommonPluginLoader(PluginLoader):
# Override
def register_base64_coder(self):
# Base64 coding
Base64.coder = _PatchBase64Coder()
# Base-64
class _PatchBase64Coder(Base64Coder):
# Override
def decode(self, string: str) -> Optional[bytes]:
string = self.trim_base64_string(b64=string)
return super().decode(string=string)
@staticmethod
def trim_base64_string(b64: str) -> str:
if '\n' in b64:
b64 = b64.replace('\n', '')
b64 = b64.replace('\r', '')
b64 = b64.replace('\t', '')
b64 = b64.replace(' ', '')
return b64.strip()This library is primarily designed to implement various algorithms in a plug-in manner, allowing you to further develop additional algorithms tailored to your specific applications.