{"_id":"56d1f33d00a2a70b00b365e3","project":"5526c95cf69851170038b48f","user":"5564b8233b87582b003ab99b","version":{"_id":"56d1f33700a2a70b00b3658e","project":"5526c95cf69851170038b48f","__v":2,"createdAt":"2016-02-27T19:04:23.946Z","releaseDate":"2016-02-27T19:04:23.946Z","categories":["56d1f33900a2a70b00b3658f","56d1f33900a2a70b00b36590","56d1f33900a2a70b00b36591","56d1f33900a2a70b00b36592","56d1f33900a2a70b00b36593","56d1f33900a2a70b00b36594","56d1f33900a2a70b00b36595","56d1f33900a2a70b00b36596","56d1f33900a2a70b00b36597","56d1f33900a2a70b00b36598","56d1f33900a2a70b00b36599","56d1f33900a2a70b00b3659a","571f9497ada30c34003b7cee"],"is_deprecated":false,"is_hidden":false,"is_beta":true,"is_stable":true,"codename":"beta","version_clean":"2.0.0-beta","version":"2.0.0-beta"},"__v":5,"category":{"_id":"56d1f33900a2a70b00b36591","__v":1,"version":"56d1f33700a2a70b00b3658e","pages":["56d1f33d00a2a70b00b365e3","56d1f33d00a2a70b00b365e4","56d1f33d00a2a70b00b365e5","56d1f33d00a2a70b00b365e6","56d1f33d00a2a70b00b365e7"],"project":"5526c95cf69851170038b48f","sync":{"url":"","isSync":false},"reference":false,"createdAt":"2015-12-04T20:08:13.640Z","from_sync":false,"order":1,"slug":"security-profiles","title":"Security Profiles"},"parentDoc":null,"updates":["561eb59653e41f0d008fe0cb","56842fca3f94e00d004e2b5f","56b1707436d2580d002478ec","57644e1389da83170059072e"],"next":{"pages":[],"description":""},"createdAt":"2015-10-05T16:08:55.801Z","link_external":false,"link_url":"","githubsync":"","sync_unique":"","hidden":false,"api":{"settings":"","results":{"codes":[]},"auth":"required","params":[],"url":""},"isReference":false,"order":0,"body":"Security Profiles group your app credentials, such as iOS certificates and Android keystores, into a single profile. They can then be used on the Ionic Platform by various services.\n[block:api-header]\n{\n  \"type\": \"basic\"\n}\n[/block]\n## Using the Dashboard\n\nSecurity Profiles and credentials can be managed in the settings page of your app at [apps.ionic.io](https://apps.ionic.io) under **Credentials**.\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/SD8d0nyuSKanUKsGJvUq_Screen%20Shot%202016-03-09%20at%209.42.10%20AM.png\",\n        \"Screen Shot 2016-03-09 at 9.42.10 AM.png\",\n        \"1268\",\n        \"1027\",\n        \"#b1965f\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]\n\n[block:image]\n{\n  \"images\": [\n    {\n      \"image\": [\n        \"https://files.readme.io/P67XFGdQTvmdEXcBbmgk_Screen%20Shot%202016-03-09%20at%209.43.23%20AM.png\",\n        \"Screen Shot 2016-03-09 at 9.43.23 AM.png\",\n        \"1268\",\n        \"1027\",\n        \"#5792ee\",\n        \"\"\n      ]\n    }\n  ]\n}\n[/block]\n\n[block:api-header]\n{\n  \"type\": \"basic\"\n}\n[/block]\n## Using the CLI\n[block:callout]\n{\n  \"type\": \"danger\",\n  \"title\": \"Unpreferred Method\",\n  \"body\": \"Push credentials are currently not supported and you may run into issues uploading your build credentials. Use of the dashboard (see above) is preferred and at some point this functionality may be removed from the CLI.\"\n}\n[/block]\n\n[block:callout]\n{\n  \"type\": \"warning\",\n  \"body\": \"Make sure you have the latest version of the Ionic CLI. You can update the CLI simply by reinstalling with npm: `npm i -g ionic`.\",\n  \"title\": \"Update the CLI\"\n}\n[/block]\n### 1. Create your first Security Profile\n\nWithin your app directory, create a security profile, and give it a nice name.\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"ionic security profiles add \\\"My First Profile\\\"\",\n      \"language\": \"shell\"\n    }\n  ]\n}\n[/block]\n### 2. Listing your profiles\n\nOnce you add your first profile, you should see it when you list your profiles with the following command.\n[block:callout]\n{\n  \"type\": \"info\",\n  \"title\": \"Note\",\n  \"body\": \"Notice the `tag` column. Security profile tags are how profiles are referenced within the Ionic Platform. You'll need to use tags to attach credentials to your new security profile.\"\n}\n[/block]\n\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"ionic security profiles list\",\n      \"language\": \"shell\"\n    }\n  ]\n}\n[/block]\n### 3. Attach iOS credentials\n\nYou can attach iOS credentials to your new profile, if you wish. If you don't have a certificate and provisioning profile downloaded locally, you can generate both by following the [iOS Build Profiles](doc:ios-build-profiles) section. Once your `.p12` certificate file and `.mobileprovision` provisioning profile file are ready, upload them and attach them to your profile using the following command:\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"ionic security credentials ios --profile my_first_profile -c ~/Downloads/Certificate.p12 -p my_certificate_password -r ~/Downloads/MyProfile.mobileprovision\",\n      \"language\": \"shell\"\n    }\n  ]\n}\n[/block]\n### 4. Attach Android Credentials\n\nIf you like, you can attach Android credentials to your new profile. If you don't have a keystore file locally, you can generate one by following [Android Build Profiles](doc:android-build-profiles) section below. Once your `.keystore` file is ready, upload it and attach it to your profile using the following command:\n[block:code]\n{\n  \"codes\": [\n    {\n      \"code\": \"ionic security credentials android --profile my_first_profile -s ~/my-release-keystore.keystore -p my_keystore_password -k my_alias -w my_key_password\",\n      \"language\": \"shell\"\n    }\n  ]\n}\n[/block]\n\n[block:callout]\n{\n  \"type\": \"success\",\n  \"title\": \"Success!\",\n  \"body\": \"Congratulations! You now have a security profile with attached credentials that you can use in the Ionic Platform.\"\n}\n[/block]","excerpt":"","slug":"security-profiles","type":"basic","title":"Overview"}
Security Profiles group your app credentials, such as iOS certificates and Android keystores, into a single profile. They can then be used on the Ionic Platform by various services. [block:api-header] { "type": "basic" } [/block] ## Using the Dashboard Security Profiles and credentials can be managed in the settings page of your app at [apps.ionic.io](https://apps.ionic.io) under **Credentials**. [block:image] { "images": [ { "image": [ "https://files.readme.io/SD8d0nyuSKanUKsGJvUq_Screen%20Shot%202016-03-09%20at%209.42.10%20AM.png", "Screen Shot 2016-03-09 at 9.42.10 AM.png", "1268", "1027", "#b1965f", "" ] } ] } [/block] [block:image] { "images": [ { "image": [ "https://files.readme.io/P67XFGdQTvmdEXcBbmgk_Screen%20Shot%202016-03-09%20at%209.43.23%20AM.png", "Screen Shot 2016-03-09 at 9.43.23 AM.png", "1268", "1027", "#5792ee", "" ] } ] } [/block] [block:api-header] { "type": "basic" } [/block] ## Using the CLI [block:callout] { "type": "danger", "title": "Unpreferred Method", "body": "Push credentials are currently not supported and you may run into issues uploading your build credentials. Use of the dashboard (see above) is preferred and at some point this functionality may be removed from the CLI." } [/block] [block:callout] { "type": "warning", "body": "Make sure you have the latest version of the Ionic CLI. You can update the CLI simply by reinstalling with npm: `npm i -g ionic`.", "title": "Update the CLI" } [/block] ### 1. Create your first Security Profile Within your app directory, create a security profile, and give it a nice name. [block:code] { "codes": [ { "code": "ionic security profiles add \"My First Profile\"", "language": "shell" } ] } [/block] ### 2. Listing your profiles Once you add your first profile, you should see it when you list your profiles with the following command. [block:callout] { "type": "info", "title": "Note", "body": "Notice the `tag` column. Security profile tags are how profiles are referenced within the Ionic Platform. You'll need to use tags to attach credentials to your new security profile." } [/block] [block:code] { "codes": [ { "code": "ionic security profiles list", "language": "shell" } ] } [/block] ### 3. Attach iOS credentials You can attach iOS credentials to your new profile, if you wish. If you don't have a certificate and provisioning profile downloaded locally, you can generate both by following the [iOS Build Profiles](doc:ios-build-profiles) section. Once your `.p12` certificate file and `.mobileprovision` provisioning profile file are ready, upload them and attach them to your profile using the following command: [block:code] { "codes": [ { "code": "ionic security credentials ios --profile my_first_profile -c ~/Downloads/Certificate.p12 -p my_certificate_password -r ~/Downloads/MyProfile.mobileprovision", "language": "shell" } ] } [/block] ### 4. Attach Android Credentials If you like, you can attach Android credentials to your new profile. If you don't have a keystore file locally, you can generate one by following [Android Build Profiles](doc:android-build-profiles) section below. Once your `.keystore` file is ready, upload it and attach it to your profile using the following command: [block:code] { "codes": [ { "code": "ionic security credentials android --profile my_first_profile -s ~/my-release-keystore.keystore -p my_keystore_password -k my_alias -w my_key_password", "language": "shell" } ] } [/block] [block:callout] { "type": "success", "title": "Success!", "body": "Congratulations! You now have a security profile with attached credentials that you can use in the Ionic Platform." } [/block]