Skip to content

Commit a5a5cbb

Browse files
committed
android: add definitions for the DeviceSerialNumber MDM key
Updates tailscale/tailscale#16010 Signed-off-by: Anton Tolchanov <[email protected]>
1 parent 1ec621c commit a5a5cbb

File tree

3 files changed

+12
-0
lines changed

3 files changed

+12
-0
lines changed

android/src/main/java/com/tailscale/ipn/mdm/MDMSettings.kt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -59,6 +59,10 @@ object MDMSettings {
5959
val postureChecking =
6060
AlwaysNeverUserDecidesMDMSetting("PostureChecking", "Enable Posture Checking")
6161

62+
// Handled on the backend
63+
val deviceSerialNumber =
64+
StringMDMSetting("DeviceSerialNumber", "Serial number of the device that is running Tailscale")
65+
6266
val useTailscaleDNSSettings =
6367
AlwaysNeverUserDecidesMDMSetting("UseTailscaleDNSSettings", "Use Tailscale DNS Settings")
6468

android/src/main/res/values/strings.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -205,6 +205,8 @@
205205
<string name="hides_the_specified_categories_of_network_devices_from_the_devices_list_in_the_client">Hides the specified categories of network devices from the devices list in the client.</string>
206206
<string name="allow_lan_access_when_using_an_exit_node">Allow LAN access when using an exit node</string>
207207
<string name="enable_posture_checking">Enable posture checking</string>
208+
<string name="device_serial_number">Serial number of the device that is running Tailscale</string>
209+
<string name="device_serial_number_descr">Allows administrators to pass the serial number of the device to Tailscale client using MDM.</string>
208210
<string name="use_tailscale_dns_settings">Use Tailscale DNS settings</string>
209211
<string name="use_tailscale_subnets">Use Tailscale subnets</string>
210212
<string name="allow_incoming_connections">Allow incoming connections</string>

android/src/main/res/xml/app_restrictions.xml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,6 +66,12 @@
6666
android:restrictionType="choice"
6767
android:title="@string/enable_posture_checking" />
6868

69+
<restriction
70+
android:description="@string/device_serial_number_descr"
71+
android:key="DeviceSerialNumber"
72+
android:restrictionType="string"
73+
android:title="@string/device_serial_number" />
74+
6975
<restriction
7076
android:entries="@array/always_never_userdecides_labels"
7177
android:entryValues="@array/always_never_userdecides"

0 commit comments

Comments
 (0)