SecureBankKit class

Public facade for the SecureBankKit security plugin.

final kit = SecureBankKit.initialize(
  enableRootDetection: true,
  enablePinning: true,
  certificatePins: {'api.bank.com': ['sha256/AAAA...']},
);

final status = await kit.runSecurityCheck();
if (!status.isSecure) { /* handle */ }

Constructors

SecureBankKit.initialize({bool enableRootDetection = true, bool enablePinning = false, bool enableAppIntegrity = true, bool enableEmulatorDetection = true, bool enableScreenRecordingDetection = false, bool enableTamperDetection = true, bool enableRuntimeProtection = true, bool enableLogging = false, Map<String, List<String>> certificatePins = const {}, PinningMode pinningMode = PinningMode.publicKey, SecurityContext? pinningSecurityContext, String tokenNamespace = 'sbk'})
Creates and returns a fully-wired SecureBankKit instance.
factory

Properties

antiTamper ↔ AntiTamper
Debugger and dynamic-library injection detection.
latefinal
biometrics ↔ Biometrics
Biometric / device-credential authentication.
latefinal
certificatePinning ↔ CertificatePinning
Public-key / certificate pinning helpers (pinned HttpClient, checks).
latefinal
hashCode → int
The hash code for this object.
no setterinherited
pasteboard ↔ Pasteboard
Local-only, auto-expiring clipboard for sensitive values.
latefinal
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited
screenCapture ↔ ScreenCapture
Live screen recording / mirroring and screenshot monitoring.
latefinal
screenshotProtection ↔ ScreenshotProtection
latefinal
secureStorage ↔ SecureStorage
latefinal
tamperDetection ↔ TamperDetection
latefinal
tokenExpiry → TokenExpiryManager
Token expiry tracking and single-flight refresh.
final
tokenStorage → SecureTokenStorage
Access / refresh token persistence on top of secure storage.
final

Methods

createAppLockManager({Duration gracePeriod = Duration.zero, bool lockOnStart = false, String reason = 'Unlock to continue', bool allowDeviceCredential = true}) → AppLockManager
Creates an AppLockManager that locks the app when it is backgrounded and unlocks it with biometrics / device credential.
createSessionManager({required Duration timeout, bool clearTokensOnExpiry = true}) → SessionManager
Creates an inactivity-based SessionManager wired to this kit's token storage, so tokens are wiped when the session times out.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
runSecurityCheck() → Future<SecurityStatus>
Runs all enabled security checks and returns a SecurityStatus.
toString() → String
A string representation of this object.
inherited

Operators

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