{"_id":"@darkedges/capacitor-secure-storage","name":"@darkedges/capacitor-secure-storage","dist-tags":{"latest":"0.1.1"},"versions":{"0.1.1":{"name":"@darkedges/capacitor-secure-storage","version":"0.1.1","description":"Capacitor 6+ plugin that provides secure storage for the iOS and Android","author":{"name":"Nicholas Irving"},"license":"MIT","main":"dist/plugin.cjs.js","module":"dist/esm/index.js","types":"dist/esm/index.d.ts","unpkg":"dist/plugin.js","engines":{"node":">=16.15.1"},"commit-and-tag-version":{"scripts":{"postbump":"pnpm builder"}},"keywords":["capacitor","plugin","native","storage","encryption"],"capacitor":{"ios":{"src":"ios"},"android":{"src":"android"}},"swiftlint":"@ionic/swiftlint-config","repository":{"type":"git","url":"git+https://github.com/darkedges/capacitor-secure-storage.git"},"bugs":{"url":"https://github.com/darkedges/capacitor-secure-storage/issues"},"devDependencies":{"@aparajita/eslint-config-base":"^1.1.6","@aparajita/prettier-config":"^2.0.0","@aparajita/swiftly":"^1.0.4","@capacitor/cli":"^6.0.0","@commitlint/cli":"^19.2.2","@commitlint/config-conventional":"^19.2.2","@ionic/swiftlint-config":"^1.1.2","@types/node":"^20.12.7","@typescript-eslint/eslint-plugin":"^7.7.0","@typescript-eslint/parser":"^7.7.0","commit-and-tag-version":"^12.4.0","eslint":"^8.57.0","eslint-config-prettier":"^9.1.0","eslint-config-standard":"^17.1.0","eslint-import-resolver-typescript":"^3.6.1","eslint-plugin-import":"^2.29.1","eslint-plugin-n":"^16.6.2","eslint-plugin-prettier":"^5.1.3","eslint-plugin-promise":"^6.1.1","nodemon":"^3.1.0","prettier":"^3.2.5","prettier-plugin-java":"^2.6.0","rimraf":"^5.0.5","rollup":"^4.16.1","simple-git-hooks":"^2.11.1","swiftlint":"^1.0.2","typescript":"~5.4.5"},"dependencies":{"@capacitor/android":"^6.0.0","@capacitor/app":"^6.0.0","@capacitor/core":"^6.0.0","@capacitor/ios":"^6.0.0"},"scripts":{"clean":"rimraf dist","lint.eslint":"eslint --fix --cache --ext .js,.cjs,.mjs,.ts --max-warnings 0","lint.prettier":"prettier --write --cache --list-different","lint.tsc":"tsc --noEmit","lint":"pnpm lint.eslint . && pnpm lint.prettier . && pnpm lint.tsc","prebuilder":"pnpm clean","builder":"tsc ${SOURCE_MAP:-} && rollup -c rollup.config.mjs","prebuild":"pnpm lint","build":"pnpm builder","build.dev":"SOURCE_MAP=--sourceMap pnpm build","watch":"nodemon --exec 'pnpm build.dev'","open.ios":"open ios/Plugin.xcworkspace","open.android":"open -b com.google.android.studio android","verify.ios":"cd ios && pod install && xcodebuild -workspace Plugin.xcworkspace -scheme Plugin -quiet && cd ..","verify.android":"cd android && ./gradlew clean build test && cd ..","verify":"pnpm verify.ios && pnpm verify.android","prerelease":"scripts/ensure-clean.sh && pnpm build","release.preview":"commit-and-tag-version --dry-run","release":"commit-and-tag-version --commit-all && git push --follow-tags && pnpm publish"},"_id":"@darkedges/capacitor-secure-storage@0.1.1","homepage":"https://github.com/darkedges/capacitor-secure-storage#readme","_integrity":"sha512-iu1DyJeztjQ+YmNjLwim9uVUuM7sLs/ZHW79AXL4cfZA6dJKYTqZ8uKOWkSLZm+Xjv+eO948yF9ieqMyhdKW5A==","_resolved":"/tmp/5b13e68728f82a954842b8b46cbc8705/darkedges-capacitor-secure-storage-0.1.1.tgz","_from":"file:darkedges-capacitor-secure-storage-0.1.1.tgz","_nodeVersion":"18.20.5","_npmVersion":"10.9.1","dist":{"integrity":"sha512-iu1DyJeztjQ+YmNjLwim9uVUuM7sLs/ZHW79AXL4cfZA6dJKYTqZ8uKOWkSLZm+Xjv+eO948yF9ieqMyhdKW5A==","shasum":"dbb789c7c00f392cbbebf798e4f4404581b2a68f","tarball":"https://registry.npmjs.org/@darkedges/capacitor-secure-storage/-/capacitor-secure-storage-0.1.1.tgz","fileCount":43,"unpackedSize":136858,"signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCIQDBmM7Ct8Uzg+QJxGl2Blo2tjjoIMicwuSDn/B2DsIQIQIgDTKfwDrutscsUTM48XHi9XEP6ryILmOGNCTEEWi9OXE="}]},"_npmUser":{"name":"darkedges","email":"developer@darkedges.com"},"directories":{},"maintainers":[{"name":"darkedges","email":"developer@darkedges.com"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/capacitor-secure-storage_0.1.1_1735528851551_0.8443320031905248"},"_hasShrinkwrap":false}},"time":{"created":"2024-12-30T03:20:51.409Z","0.1.1":"2024-12-30T03:20:51.718Z","modified":"2024-12-30T03:20:51.974Z"},"maintainers":[{"name":"darkedges","email":"developer@darkedges.com"}],"description":"Capacitor 6+ plugin that provides secure storage for the iOS and Android","homepage":"https://github.com/darkedges/capacitor-secure-storage#readme","keywords":["capacitor","plugin","native","storage","encryption"],"repository":{"type":"git","url":"git+https://github.com/darkedges/capacitor-secure-storage.git"},"author":{"name":"Nicholas Irving"},"bugs":{"url":"https://github.com/darkedges/capacitor-secure-storage/issues"},"license":"MIT","readme":"<div class=\"markdown-body\">\n\n# capacitor-secure-storage\n\nThis plugin for [Capacitor 6+](https://capacitorjs.com) provides secure key/value storage on iOS and Android. It was originally designed to be a companion to [@aparajita/capacitor-biometric-auth](https://github.com/aparajita/capacitor-biometric-auth/#readme) in order to securely store login credentials, but can be used to store any JSON data types.\n\n## BREAKING CHANGES: Upgrading from 5.x\n\nThe minimum Android API level was increased from 22 to 23 (Android 6).\n\n## BREAKING CHANGES: Upgrading from 2.x\n\nTo be consistent with JavaScript’s `Storage` and `@capacitor/preferences`, the plugin now returns `null` instead of throwing an exception when getting a non-existent item.\n\nAlso, the plugin no longer encrypts data on the web, since this plugin is designed for native storage, and including blowfish was unnecessary bloat.\n\n## Installation\n\n```sh\npnpm add @aparajita/capacitor-secure-storage # npm install, yarn add\n```\n\nNot using [pnpm](https://pnpm.js.org/)? You owe it to yourself to give it a try. It’s faster, better with monorepos, and uses _way, way_ less disk space than the alternatives.\n\n## Usage\n\nThe API is thoroughly documented [here](src/definitions.ts). For a complete example of how to use this plugin in practice, see the [demo app](https://github.com/aparajita/capacitor-secure-storage-demo).\n\n### iOS\n\nOn iOS, data is stored in the encrypted system keychain and is specific to your app. Please note that currently iOS will **not** delete an app’s keychain data when the app is deleted. But since only an app with the same app id — which is guaranteed by Apple to be unique across all apps — can access that data, this is not a security issue.\n\n#### iCloud Keychain sync\n\nYou may synchronize data with iCloud Keychain. Synchronization can be controlled globally and per operation. This allows you to share secure data (such as login credentials) for the same app across multiple devices.\n\n> 👉 The user must enable iCloud Keychain on a device in order for data to sync.\n\nTo turn sync on or off globally, call `setSynchronize()`. You can override the global setting per operation by passing a boolean in the `sync` option.\n\nNote that iOS considers the local keychain and iCloud keychain as two separate keychains. Which keychain is affected by an operation depends on the global and per operation sync setting. This means, for example, that a value can be stored and retrieved with the same key in both keychains.\n\n> 👉 When the resolved sync setting is true, calls to `keys()` return the keys for **both** the iCloud and local keychains. Thus there may be duplicates.\n\n### Android\n\nOn Android, data is encrypted using AES in GCM mode with a secret key generated by the Android KeyStore, then stored in SharedPreferences, which is specific to your app. If the app is deleted, its data is deleted as well.\n\n### Web\n\nOn the web, data is stored **unencrypted** in `localStorage`, so that you can see the data you are storing. This is for debugging purposes only; you should not use this plugin on the web in production.\n\n</div>\n","readmeFilename":"README.md"}