{"id":15018490,"url":"https://github.com/nativescript/ios-mobileprovision-finder","last_synced_at":"2025-07-13T06:36:31.865Z","repository":{"id":57276307,"uuid":"75385825","full_name":"NativeScript/ios-mobileprovision-finder","owner":"NativeScript","description":"API to find an iOS mobile provision","archived":false,"fork":false,"pushed_at":"2023-03-21T16:53:51.000Z","size":273,"stargazers_count":5,"open_issues_count":8,"forks_count":4,"subscribers_count":23,"default_branch":"master","last_synced_at":"2024-10-29T15:51:55.002Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/NativeScript.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2016-12-02T10:28:11.000Z","updated_at":"2024-10-24T12:31:56.000Z","dependencies_parsed_at":"2022-08-25T03:41:44.576Z","dependency_job_id":"ae745577-1b37-454d-9958-6ea14f1e44ee","html_url":"https://github.com/NativeScript/ios-mobileprovision-finder","commit_stats":{"total_commits":38,"total_committers":7,"mean_commits":5.428571428571429,"dds":0.2894736842105263,"last_synced_commit":"03a4863874329cf8a8ccf0b4a5b92670a76e2f64"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NativeScript%2Fios-mobileprovision-finder","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NativeScript%2Fios-mobileprovision-finder/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NativeScript%2Fios-mobileprovision-finder/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/NativeScript%2Fios-mobileprovision-finder/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/NativeScript","download_url":"https://codeload.github.com/NativeScript/ios-mobileprovision-finder/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":237163243,"owners_count":19265234,"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":"2024-09-24T19:52:01.764Z","updated_at":"2025-02-04T17:31:44.960Z","avatar_url":"https://github.com/NativeScript.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"API to find an iOS mobile provision\n\n[![Build Status](https://travis-ci.org/NativeScript/ios-mobileprovision-finder.svg?branch=master)](https://travis-ci.org/NativeScript/ios-mobileprovision-finder)\n\n## Using as command line tool\n```\nUsage: ios-mobileprovision-finder -u [device uuid] -i [app bundle id]\n\nOptions:\n  -h, --help      Show help                                            [boolean]\n  -u, --uuid      Provide one or more device UUIDs the searched provisioning\n                  profile should be able to deploy to.                   [array]\n  -i, --app-id    Provide application bundle identifier the searched\n                  provisioning profile should match.                    [string]\n  -e, --eligible  Prints only eligible profiles       [boolean] [default: false]\n  -t, --team      Provide team name the provisioning profile should belong to.\n                                                                        [string]\n  -p, --type      'development', 'distribution', 'adhoc' or 'all'; - specify the\n                  provisioning profile type.   [string] [default: \"development\"]\n```\n\nExample:\n```\nmcsofcankov:ios-mobileprovision-finder cankov$ ios-mobileprovision-finder -e -i org.nativescript.examples -t 'Telerik A D'\neligible:\n - 'iOS Team Provisioning Profile: *' Telerik A D (exp: 5 Nov 2017) 16455071-eb38-4ebc-9a79-0ef50f76307a id: CHSQ3M3P37.* Development\n - 'NativeScriptWildCard' Telerik A D (exp: 2 Nov 2017) 3aa58a65-f8da-4c67-bce8-ff9624822e31 id: CHSQ3M3P37.* Development\n - 'iOS Team Provisioning Profile: org.nativescript.examples' Telerik A D (exp: 5 Nov 2017) f79232c0-b3b3-4b9d-be8e-f4f398cead88 id: CHSQ3M3P37.org.nativescript.examples Development\n```\n\n## JavaScript API\nRead the public API from index.d.ts and the ios-mobileprovision-finder.ts command line tool for example.\n\n``` TypeScript\nimport { provision, cert } from \"./index\";\n\nconst certificates = cert.read();\nconst provisionProfiles = provision.read();\nconst result = provision.select(provisionProfiles, {\n    AppId: \"org.nativescript.examples\",\n    TeamName: \"Telerik AD\",\n    Certificates: certificates.valid\n});\nresult.eligible.forEach(({Name, UUID}) =\u003e {\n    console.log(` - ${Name} ${UUID}`);\n});\n```\n\n## Under the hood\n### Provisioning profiles\nRead all files in Library/MobileDevice/Provisioning Profiles/ and scan for the plist containing provisioning profile information.\nParse the plist and keep the data.\n\n### Certificates\nList all the valid certificates in the default keychain search list using:\n```\nsecurity find-identity -p codesigning\n```\nIt yelds output such as:\n```\n  1) FAE6210D184FCC1707B87F1C582280A286898EE3 \"iPhone Distribution: Telerik A D (CHSQ3M3P37)\"\n  2) 89936062DD52C7FEF2273E677AC98D109F198A84 \"iPhone Developer: Panayot Cankov (3KZR3BE4ZD)\" (CSSMERR_TP_CERT_REVOKED)\n  3) 0F0077D3EBEA9D0AB6668B8BCB90152ACE7BA4E9 \"iPhone Developer: Panayot Cankov (TT4M4FMX2A)\" (CSSMERR_TP_CERT_REVOKED)\n  4) 07AB20E16C86E2B548A91920B83EC27D78AFC7EB \"iPhone Developer: Panayot Cankov (3KZR3BE4ZD)\"\n  5) 9354FAEF631DC3E9B07929F20991829FF5E21C36 \"iPhone Developer: Panayot Cankov (TT4M4FMX2A)\"\n  6) 9D591A6ADAF9C99A9C19FC1A8EE7FA153C613441 \"iPhone Distribution: Telerik AD\"\n```\nThat is then parsed and the PEMs are retrieved using:\n```\nsecurity find-certificate -apZ\n```\n\nThis prints the certificate SHAs, match ths SHA with the valid certs from the previous step, along PEMs.\nThe PEMs and cert names are combined and later certificates can be matched with the certificates in the provisioning profiles.\n\nThis relies on the cert hashes.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnativescript%2Fios-mobileprovision-finder","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fnativescript%2Fios-mobileprovision-finder","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fnativescript%2Fios-mobileprovision-finder/lists"}