Name | Description |
---|---|
Action | com.symbol.wfc.pttpro.ACTION_LOGIN |
Intent Type | broadcast |
Extra 0 | This extra specifies the username. This is a mandatory parameter if the login_info parameter is not included. |
Type | String |
Name | user_name |
Value | Username with domain (For example; sample.user@domain ) |
Extra 1 | This extra specifies the user password. This is a mandatory parameter if the login_info parameter is not included. |
Type | String |
Name | user_pwd |
Value | User Password |
Extra 2 | This extra specifies if the JSON login information is encrypted. This is an optional parameter. |
Type | Boolean |
Name | json_encrypted |
Value | True indicates the login information is encrypted. False or absent indicates the information is not encrypted. |
Extra 3 | This extra login_info specifies the JSON login information. See below for the payload definition. This extra may or may not be encrypted. |
Extra 3 - sent unencrypted | This extra specifies the JSON login information when not encrypted. This is an optional parameter. |
Type | String |
Name | login_info |
Value | String in JSON format |
Extra 3 – sent encrypted | This extra specifies the JSON login information when encrypted. This is an optional parameter. |
Type | Byte array |
Name | login_info |
Value | See code snippet |
adb shell am broadcast -a com.zebra.dfs.ACTION_LOGIN --es user_name --es user_pwd --es <other login parameters>
adb shell am broadcast -a com.zebra.dfs.ACTION_LOGIN –es json_encrypted false--es login_info {user_name:sample.user@domain, user_pwd:<password>}
{"user_name": "username", //mandatory "user_pwd": "userpwd", //mandatory "package": "<third_party_package_name>" //optional; }
Config String | Description | Type | Default |
---|---|---|---|
secret_key | <Optional> This value is used to decrypt the login_info when ACTION_LOGIN intent is sent with json_encrypted= true. key length must be 32 characters or UUID where PTT Pro for Android accepts 36 characters and remove the "-" character.
For example: "5ecded3e-9562-11ea-bb37-0242ac130002" is converted as "5ecded3e956211eabb370242ac130002" | String | "" |
key_domain | <Optional> If this value is configured, the domain name is added to the "user_name".
For example; testuser3 becomes testuser3@pttpro if key_domain is configured as "pttpro". | String | "" |
key_user_name | <Optional> Used with third-party launcher apps. This tag identifies the Username ID attribute and allows input on the current login web page. Sample HTML: """<input id= userNameInput name="UserName" type="email" class="text fullWidth" value="">""" | String | "userNameInput" |
key_user_pwd | <Optional> Used with third-party launcher apps. This tag identifies the Password ID attribute and provides input on the current login web page. Sample HTML:"""<input id= passwordInput name="Password" type="password" class="text fullWidth" placeholder="Password" autocomplete="off">""" | String | "submitButton" |
key_submit | <Optional> Used with third-party launcher apps. This tag identifies the Submit ID attribute for acceptance of credentials on the current login web page. Sample.html: """ <button id= submitButton type="submit" disabled="" tabindex="0" width="1" kind="primary">""" | String | "submitButton" |
adb shell am broadcast -a com.symbol.wfc.pttpro.ACTION_LOGIN --es user_name 'testuser3@pttpro' --es user_pwd 'pwdFor2022!' com.symbol.wfc.pttpro
adb shell am broadcast -a com.symbol.wfc.pttpro.ACTION_LOGIN --es user_name 'testuser3' --es user_pwd 'pwdFor2022!' com.symbol.wfc.pttpro
adb shell am broadcast -a com.symbol.wfc.pttpro.ACTION_LOGIN --ez json_encrypted false --es login_info '{"user_name":"testuser3@pttpro", "user_pwd":"pwdFor2022!"}' com.symbol.wfc.pttpro
adb shell am broadcast -a com.symbol.wfc.pttpro.ACTION_LOGIN --ez json_encrypted false --es login_info '{"user_name":"testuser3", "user_pwd":"pwdFor2022!"}' com.symbol.wfc.pttpro
String aad = ""; String secret_key = "5ecded3e-9562-11ea-bb37-0242ac130002"; //Example: UUID // Encryption JSONObject data = new JSONObject(); data.put("user_name", "testuser3@pttpro"); data.put("user_pwd", "pwdFor2022!"); data.put("package", "com.example.launcherapp"); AesGcmJce agjEncryption = new AesGcmJce(secret_key.getBytes()); byte[] encrypted = agjEncryption.encrypt(data.toString().getBytes(), aad.getBytes()); //send encryped data Intent intent = new Intent("com.symbol.wfc.pttpro.ACTION_LOGIN"); intent.putExtra("login_info", encrypted); intent.putExtra("json_encrypted", true); intent.setPackage("com.symbol.wfc.pttpro"); sendBroadcast(intent);