## Abstract This example SIP adds generic algorithm as an algorithmic type. ## Motivation Generic algorithm has a good reason to be in Sila, therefore it should be. ## Specification This SIP defines a new [SIP-7932](../../SIPS/sip-7932.md) algorithmic type with the following parameters. ```python ALG_TYPE = 0xFA SIZE = 128 def gas_cost(signing_data: Bytes) -> Uint64: return Uint64(128 + len(signing_data)) def validate(signature: Bytes) -> None | Error: # ... # Simple cryptography here # ... return None def verify(signature: Bytes, signing_data: Bytes) -> Bytes | Error: # ... # Complicated cryptography here # ... return public_key def merge_detached_signature(detached_signature: bytes, public_key: bytes) -> bytes: # ... # Either concatenation or a no-op here # ... return detached_signature + public_key ``` ## Rationale Generic algorithm has a good reason to be in Sila, therefore it should be. ## Backwards Compatibility No backward compatibility issues found. ## Security Considerations Needs discussion. ## Copyright Copyright and related rights waived via [CC0](../../LICENSE.md).