Wifi Hotspot Timeout in Samsung Devices
In the past, the command you could use to set no timeout for Wifi hotspot on Samsung Android+ agent was
writesecuresetting -sec wifi_ap_timeout_setting 0
This may not work any more for newer agents/firmware versions, or when some permissions of your MobiControl agent are disabled on your device model.
I tried the script but it didn't work
I also noted that the hotspot is not enabled, only configured, so the user has to go to settings and enable it.
Is there any way to enable the hotspot automatically?
Thank you Raymod,
To enable Wifi hotspot on Android+ device (not just for Samsung), use the following script command:
Due to change of security/app-permission model in recent versions of Android defined by Google, this might also not work. In one extreme case, we had test device with this command working at one time and failing at another within an hour of repeated tests, and we are still trying to determine what factor(s) are crucial, and a way to guarantee that it always works.
The same argument applies to the writesecuresetting command given in the previous post. The syntax/command-arguments are definitely right on all Samsung Android+ devices. The real issue is the security/permission to use this command to write settings (i.e. ANY setting, and NOT just this one for "Wifi Hotspot timeout") on the device. Device firmware version, agent version, and some Android permissions configured by device user in Settings are some of the factors that can affect whether it works or not. We are trying to figure out if there is a proper way to follow, so that it always works every time just like two or three years ago.
That worked fine. We finally use a script file in the lockdown to enable the wifi hotspot.
Thank you very much
Did you make any change on your device to make the script commands work?
What device model(s), Android version(s) and MC server/agent versions have you successfully deployed the scripts?
I did not really make any changes in device settings. These are Samsung J7 with Android 7 and Android 6.
The script file just has the following:
With this, we make sure the wifi hotspot is enabled when the app is launched.
Raymond, Has any progress been made on newer Android versions as well as enterprise devices on this subject?
It seems that the old script command to some settings has been added back to Android Enterprise platform device agent recently. However, I still haven't successfully use such command mentioned in the release notes to make settings changes. One reason why I haven't spent much time exploring is that commands used to support this flow to get information about the parameters/arguments seem to be still missing.