{"id":26543784,"url":"https://github.com/backbase/mobile-encryption-accelerator","last_synced_at":"2025-03-22T03:15:24.488Z","repository":{"id":271933240,"uuid":"913326912","full_name":"Backbase/mobile-encryption-accelerator","owner":"Backbase","description":"Encryption Accelerator for mobile projects ","archived":false,"fork":false,"pushed_at":"2025-01-07T13:25:08.000Z","size":107,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":6,"default_branch":"main","last_synced_at":"2025-03-19T12:52:38.108Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Swift","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Backbase.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2025-01-07T13:22:49.000Z","updated_at":"2025-01-07T13:25:12.000Z","dependencies_parsed_at":"2025-01-10T21:15:45.154Z","dependency_job_id":null,"html_url":"https://github.com/Backbase/mobile-encryption-accelerator","commit_stats":null,"previous_names":["backbase/mobile-encryption-accelerator"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Backbase%2Fmobile-encryption-accelerator","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Backbase%2Fmobile-encryption-accelerator/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Backbase%2Fmobile-encryption-accelerator/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Backbase%2Fmobile-encryption-accelerator/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Backbase","download_url":"https://codeload.github.com/Backbase/mobile-encryption-accelerator/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244898458,"owners_count":20528341,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2025-03-22T03:15:23.982Z","updated_at":"2025-03-22T03:15:24.483Z","avatar_url":"https://github.com/Backbase.png","language":"Swift","funding_links":[],"categories":[],"sub_categories":[],"readme":"\n# Mobile Encryption Accelerator\n\nThis accelerator provides functionalities for RSA encryption and decryption. It allows you to encrypt data using either a public key provided by the Identity Realm or a public key provided by any other means, and decrypt data encrypted with the corresponding private key.\n\n## Features\n\n- Generate RSA key pairs\n- Encrypt data using a public key\n- Decrypt data using a private key\n- Supports different key sizes (512, 1024, 2048, 3072, 4096 bits)\n- Allows specifying a custom cipher type\n\n## Constructors\n\n- `BBRSACryptor(keySize: KeySize)`: Creates a new instance with a randomly generated key pair of the specified size.\n- `BBRSACryptor(publicKey: String, privateKey: String)`: Creates a new instance with the provided public and private keys (Base64 encoded).\n- `BBRSACryptor(keySize: KeySize, cipherType: String)`: Creates a new instance with a randomly generated key pair of the specified size and cipher type.\n- `BBRSACryptor(publicKey: String, privateKey: String, cipherType: String)`: Creates a new instance with the provided public and private keys (Base64 encoded) and cipher type.\n\n## Methods\n\n- `getPublicKey()`: Returns the public key as a Base64 encoded string.\n- `getPrivateKey()`: Returns the private key as a Base64 encoded string.\n- `encrypt(message: String)`: Encrypts the given message using the public key.\n- `encrypt(message: String, publicKey: String)`: Encrypts the given message using the provided public key (Base64 encoded).\n- `decrypt(encryptedMessage: String)`: Decrypts the given encrypted message using the private key.\n- `decrypt(encryptedMessage: String, privateKey: String)`: Decrypts the given encrypted message using the provided private key (Base64 encoded).\n\n## Example Usage\n\n```\n// Generate a new key pair with a key size of 2048 bits\nval cryptor = BBRSACryptor.create(BBRSACryptor.KeySize.BIT_2048)\n\n// Get the public and private keys\nval publicKey = cryptor.getPublicKey()\nval privateKey = cryptor.getPrivateKey()\n\n// Encrypt a message using the public key\nval message = \"This is a secret message\"\nval encryptedMessage = cryptor.encrypt(message)\n\n// Decrypt the encrypted message using the private key\nval decryptedMessage = cryptor.decrypt(encryptedMessage)\n\nprintln(decryptedMessage) // Output: This is a secret message\n```\n\n## Important Notes\n\n- Ensure that the provided public and private keys are valid and compatible with each other.\n- Choose an appropriate key size based on your security requirements.\n- This library uses Base64 encoding for public and private keys.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbackbase%2Fmobile-encryption-accelerator","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbackbase%2Fmobile-encryption-accelerator","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbackbase%2Fmobile-encryption-accelerator/lists"}