{"id":23174062,"url":"https://github.com/zebradevs/oeminfo_with_stagenow","last_synced_at":"2025-04-05T00:26:17.047Z","repository":{"id":233636481,"uuid":"753528031","full_name":"ZebraDevs/OEMINFO_WITH_STAGENOW","owner":"ZebraDevs","description":null,"archived":false,"fork":false,"pushed_at":"2024-02-14T08:59:08.000Z","size":300,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-02-10T08:51:22.411Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ZebraDevs.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,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-02-06T09:55:21.000Z","updated_at":"2024-02-06T10:05:29.000Z","dependencies_parsed_at":null,"dependency_job_id":"f723aa9f-5ff7-4a17-93f6-fb47f1c8a42a","html_url":"https://github.com/ZebraDevs/OEMINFO_WITH_STAGENOW","commit_stats":null,"previous_names":["zebradevs/oeminfo_with_stagenow"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ZebraDevs%2FOEMINFO_WITH_STAGENOW","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ZebraDevs%2FOEMINFO_WITH_STAGENOW/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ZebraDevs%2FOEMINFO_WITH_STAGENOW/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ZebraDevs%2FOEMINFO_WITH_STAGENOW/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ZebraDevs","download_url":"https://codeload.github.com/ZebraDevs/OEMINFO_WITH_STAGENOW/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247268410,"owners_count":20911131,"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-12-18T05:19:03.566Z","updated_at":"2025-04-05T00:26:17.026Z","avatar_url":"https://github.com/ZebraDevs.png","language":"Java","funding_links":[],"categories":[],"sub_categories":[],"readme":"Please be aware that this application / sample is provided as-is for demonstration purposes without any guarantee of support\n=========================================================\n\n# OEM_INFO_EXERCISER (from the original code of EMDK-DeviceIdentifiers-Sample)\nShowing Zebra OEMInfo capabilities \n\nRefer to https://techdocs.zebra.com/oeminfo/about/ for instruction about how to grant this app to access OEMInfo.\n\nTo retrieve the app's signature for Stagenow get https://techdocs.zebra.com/emdk-for-android/latest/samples/sigtools/\n\nCommand to get the signature:\njava -jar SigTools.jar getcert -inform apk -outform der -in app.apk -outfile app.crt\n\n\n\n\nHow to access device identifiers such as serial number and IMEI on Zebra devices running Android 10\n\nAndroid 10 limited access to device identifiers for all apps running on the platform regardless of their target API level.  As explained in the docs for [Android 10 privacy changes](https://developer.android.com/about/versions/10/privacy/changes) this includes the serial number, IMEI and some other identifiable information.\n\n**Zebra mobile computers running Android 10 are able to access both the serial number and IMEI** however applications need to be **explicitly granted the ability** to do so and use a proprietary API.\n\nTo access the serial number and IMEI file on Zebra Android devices running Android 10 or higher, first declare a new permission in your AndroidManifest.xml\n\n```xml\n\u003cuses-permission android:name=\"com.zebra.provider.READ\"/\u003e\n```\n\nThen use the [MX access manager](https://techdocs.zebra.com/mx/accessmgr/) to allow your application to call the service identifiers associated with the serial number and IMEI\n\nThe MX access manager settings to enable this are as follows:\n- Service Access Action: \"AllowCaller\" (or 'Allow Caller to Call Service')\n- Service Identifier: For the serial number use content://oem_info/oem.zebra.secure/build_serial.  For the IMEI use content://oem_info/wan/imei.  If you want to allow your app access to both, you will need to declare two different instances of the AccessManager.\n- Caller Package Name: Your *```applicationID```*, as it appears in the module's build.gradle file. e.g.\n    ![image](https://github.com/ZebraDevs/OEMINFO_WITH_STAGENOW/assets/11386676/e47a5323-c8e8-45d6-803d-440a5ad96d7e)\n\n- Caller Signature: The signing certificate of your application.  For more information on generating this see https://github.com/darryncampbell/MX-SignatureAuthentication-Demo.\n\nYou can apply the MX access manager settings in one of three ways:\n1. Via StageNow\n2. Via your EMM\n3. Via your application, using the EMDK Profile Manager.\n\nFor example, StageNow will look as follows to enable access to the serial number:\n\n![StageNow](https://github.com/darryncampbell/EMDK-DeviceIdentifiers-Sample/raw/master/screenshots/stagenow.png)\n\nYou can then run this sample app and should see something like the below:\n\n![Working](https://github.com/darryncampbell/EMDK-DeviceIdentifiers-Sample/raw/master/screenshots/working.jpg)\n\nOr, on a device that does not have WAN capabilities, i.e. no SIM card or data connection: \n\n![Non-WAN](https://github.com/darryncampbell/EMDK-DeviceIdentifiers-Sample/raw/master/screenshots/non_wan.jpg)\n\n## Handling errors:\n\nIf you failed to correctly allow your application access to oem_info service, you will see an error stating so against each property you did not assign access to, as shown below:\n\n![no_service_access](https://github.com/darryncampbell/EMDK-DeviceIdentifiers-Sample/raw/master/screenshots/no_service_access.jpg)\n\nAssign access to your device and re-run the application.\n\n## Changes to Package visibility in Android 11\n\nApplications targeting SDK 30 (Android 11) will need to confirm to the package visibility filtering on Android as described in the Android documentation at [https://developer.android.com/training/package-visibility](https://developer.android.com/training/package-visibility) and [https://developer.android.com/training/package-visibility](https://developer.android.com/training/package-visibility/declaring)\n\nTo grant visility by authority, add the following to your manifest:\n\n```xml\n\u003cqueries\u003e\n    \u003cpackage android:name=\"com.zebra.zebracontentprovider\" /\u003e\n\u003c/queries\u003e\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzebradevs%2Foeminfo_with_stagenow","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fzebradevs%2Foeminfo_with_stagenow","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fzebradevs%2Foeminfo_with_stagenow/lists"}