SecurityConfig class

Security-related configuration options for IPFS node

Constructors

SecurityConfig({bool enableTLS = false, String? tlsCertificatePath, String? tlsPrivateKeyPath, bool enableKeyRotation = true, Duration keyRotationInterval = const Duration(days: 30), int maxAuthAttempts = 3, bool enableRateLimiting = true, int maxRequestsPerMinute = 100, int dhtDifficulty = 0})
Creates a new SecurityConfig with default encryption and rotation settings.
const
SecurityConfig.fromJson(Map<String, dynamic> json)
Creates a SecurityConfig from a JSON map.
factory

Properties

dhtDifficulty int
SEC-005: Static PoW difficulty for DHT Sybil protection (number of zero bits)
final
enableKeyRotation bool
Whether to enable key rotation
final
enableRateLimiting bool
Whether to enable request rate limiting
final
enableTLS bool
Whether to enable TLS for secure communication
final
hashCode int
The hash code for this object.
no setterinherited
keyRotationInterval Duration
Key rotation interval
final
maxAuthAttempts int
Maximum number of authentication attempts
final
maxRequestsPerMinute int
Maximum requests per minute
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
tlsCertificatePath String?
The path to the TLS certificate file
final
tlsPrivateKeyPath String?
The path to the TLS private key file
final

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toJson() Map<String, dynamic>
Converts this configuration to a JSON map.
toString() String
A string representation of this object.
inherited

Operators

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