EncryptionAlgorithm enum

Encryption algorithms supported by SyncLayer.

Each algorithm has different characteristics:

  • AES-256-GCM: Best balance of security and performance (recommended)
  • AES-256-CBC: Standard AES encryption
  • ChaCha20-Poly1305: Modern, fast, mobile-optimized
Inheritance
Available extensions

Values

aes256GCM → const EncryptionAlgorithm

AES-256-GCM (Galois/Counter Mode)

  • Security: Excellent (authenticated encryption)
  • Performance: Very good (hardware acceleration)
  • Use case: General purpose, recommended for most apps
  • Key size: 256 bits
  • IV size: 96 bits (12 bytes)

Best for: Healthcare, finance, enterprise apps

aes256CBC → const EncryptionAlgorithm

AES-256-CBC (Cipher Block Chaining)

  • Security: Good (requires HMAC for authentication)
  • Performance: Good (hardware acceleration)
  • Use case: Legacy compatibility
  • Key size: 256 bits
  • IV size: 128 bits (16 bytes)

Best for: Compatibility with existing systems

chacha20Poly1305 → const EncryptionAlgorithm

ChaCha20-Poly1305

  • Security: Excellent (authenticated encryption)
  • Performance: Excellent on mobile (no hardware needed)
  • Use case: Mobile-first apps
  • Key size: 256 bits
  • Nonce size: 96 bits (12 bytes)

Best for: Mobile apps, IoT devices

Properties

hashCode int
The hash code for this object.
no setterinherited
index int
A numeric identifier for the enumerated value.
no setterinherited
name String

Available on Enum, provided by the EnumName extension

The name of the enum value.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Constants

values → const List<EncryptionAlgorithm>
A constant List of the values in this enum, in order of their declaration.