TrusToken is a comprehensive mobile application designed for secure digital wallet management, user authentication, and seamless financial transactions. Built with Kotlin and Jetpack Compose, the app provides a robust and user-friendly experience for managing digital assets and payments.
TrusToken leverages several critical native cryptographic functions to enhance security:
| Function | Purpose | Usage in Application |
|---|---|---|
| libint(int) | Integer manipulation | Low-level computational operations |
| login(tokenPin) | User Authentication | Secure USB token-based login |
| signData() | Transaction Signing | Cryptographically sign transactions |
| verify(string, plainText) | Signature Verification | Validate transaction authenticity |
| encrypt() | Data Encryption | Secure sensitive information |
| decrypt(string) | Data Decryption | Retrieve original sensitive data |
| logout() | Session Termination | Securely end user session |
In the ActivationViewModel, the login() native function is used during PIN verification:
- Validates user credentials against USB token
- Provides a secure, hardware-based authentication mechanism
- Prevents unauthorized access with cryptographic verification
In the HomeViewModel, native functions play crucial roles:
- signData(): Generates cryptographic signatures for transactions
- verify(): Validates transaction signatures before processing
- logout(): Logout Session form TrusToken after verification
- Ensures transaction integrity and non-repudiation
- encrypt() and decrypt() protect sensitive user and transaction data
- Prevents unauthorized data access
- Provides an additional layer of security beyond standard encryption
The application follows a clean, modular architecture with clear separation of concerns:
- Presentation Layer: Jetpack Compose UI components
- Domain Layer: Business logic and use cases
- Data Layer: Service implementations and data management
- Core Layer: Shared utilities, navigation, and dependency injection
- Sign Up Screen:
- New user registration
- Secure account creation
- Login Screen:
- User authentication
- Credential validation
- Forget Password:
- Password reset functionality
- Change password interface
- Implements secure sign-in methods
- Generates and manages user wallet addresses
- Handles authentication states
- Provides error handling for authentication processes
- Wallet Creation: Secure wallet generation
- Transaction Handling:
- Transaction listing
- Transaction details view
- Transaction parsing and management
- Payment Screen:
- Initiate and confirm payments
- Transaction confirmation
- Transaction List Screen:
- View transaction history
- Native functions provide hardware-level security
- USB token acts as a physical authentication factor
- Cryptographic operations executed in secure native environment
- Hardware-based authentication
- Cryptographic transaction signing
- Secure data encryption/decryption
- Tamper-resistant transaction verification
- Custom themed screens
- Responsive design
- Material Design principles
- Custom fonts (Poppins, Roboto)
- Adaptive UI components
- Home Screen
- User Profile
- Payment Screens
- Authentication Screens
- Transaction Screens
- Primary Language: Kotlin
- UI Framework: Jetpack Compose
- Architecture: Clean Architecture, MVVM + MVI,
- Dependency Injection: Koin
- Database: Firestore, Firebase Realtime Database, Firebase Storage
- C++ cryptographic libraries
- PKCS#11 support
- Native method integrations
saurav1375-trustathon/
βββ app/
β βββ src/
β β βββ main/
β β β βββ java/com/example/trustoken_starter/
β β β β βββ auth/ # Authentication modules
β β β β βββ core/ # Core utilities
β β β β βββ di/ # Dependency Injection
β β β β βββ payment/ # Payment-related modules
β β β β βββ ui/ # UI Theme and Components
β β β β βββ ...
β β β βββ res/ # Resources
β β βββ ...
βββ ...
- Secure User Authentication
- Digital Wallet Management
- Transaction Processing
- PIN Verification
- Responsive UI Design
- Comprehensive Error Handling
- Clone the repository
- Open in Android Studio
- Sync Gradle dependencies
- Build and run the project
- Android Studio
- Kotlin SDK
- Gradle
- Android SDK
- Jetpack Compose
- Kotlin Coroutines
- Native C++ Libraries
- Koin Dependency Injection
- Implements secure authentication mechanisms
- Uses native cryptographic libraries
- Comprehensive error and network error handling
- Secure wallet address generation
- Generalized Campus Currency Framework
- Each institution can create and manage its own digital currency
- Customizable token economics for specific campus needs
- Easy integration with existing campus infrastructure
- Scalable token creation mechanism
- Institution-specific currency management
- Transparent and secure transaction tracking
- Shop User Type
- Special user category for campus vendors and shops
- Simplified payment acceptance mechanism
- Integrated point-of-sale (POS) system
- USB Token-based instant payments
- Plug-and-play payment system for merchants
- Real-time transaction verification
- Advanced Security Layers
- Biometric signature for transactions
- Multi-factor authentication
- Secure data signing using biometric credentials
- Fingerprint transaction authorization
- Facial recognition for high-value transactions
- Seamless, secure user verification
- Implement native biometric signing functions
- Extend current native cryptographic library
- Create abstraction layers for biometric integration
- Create a replicable, secure digital transaction ecosystem
- Empower educational institutions with custom financial technologies
- Provide students with modern, secure financial tools
- Simplified campus financial interactions
- Reduced cash handling
- Enhanced financial transparency
- Technological innovation in educational financial systems
This is a sample application and should not be used for production without proper security audits and enhancements.




