How to Use iOS Devices With Passcode on KOBITON System

Adam Creamer

Reading Time : 4min read

For better security, you can set a passcode that needs to be entered to unlock iPhone/ iPad when you turn it on or wake it. Setting a passcode turns on data protection, which encrypts your iPhone/ iPad data with 256-bit AES encryption to protect the personal information — financial details, photos, emails, texts, and more — that’s stored on the mobile device. Without a passcode, anyone who has physical access to the device can access that information.

Do you know you can automate the tests on your apps with iOS devices that have a passcode? Today, on this tutorial, I will guide to configure the iOS devices with a passcode and execute the tests with the Kobiton system.

Install and configure Apple Configurator 2

Apple Configurator 2 makes it easy to deploy iPad, iPhone, iPod touch, and Apple TV devices in your institution. Apple’s Configurator 2 app configures and locks down devices against unauthorized changes by end-users.

We can get all information about the device in detail such as Apps, Profiles, or the device logs in the Console.

Or, we can supervise and enroll the devices in our MDM server.

Let’s get started!

First of all, we need to install Automation Tools cfgutil by selecting Apple Configurator 2 -> Install Automation Tools.

Then click the Install button

The next popup is displayed and required you to enter your credential account to install it.

Set up Organization with Apple Configurator 2

An organization contains the contact information and supervision identity for a supervised device. The contact information will be shown under Settings -> General -> About on supervised devices, and cannot be changed without erasing the devices. From the Apple Configurator 2 menu on your Mac, choose Preferences > Organizations. You can then do the following:

Create/ Import an Organization

If you don’t have an Organization, you need to create an Organization with Apple Configurator 2. Please access Organization preferences in Apple Configurator 2 on Mac to set up your Organization (Supervision Identity) with the Apple official guideline.

If you have an Organization, you can import it into Organizations with the following steps:

  • Click the Gear pop-up menu, select Import Organization, locate your organization file, then click Import.
  • Enter the password used to encrypt the file, then click Submit.

Export Supervision Identity

  • Select your organization from the list, click the Gear pop-up menu, then choose “Export Supervision Identity
  • Make sure the format is Unencrypted DER (.crt and .der, for Automator and cfgutil)
  • Enter a name Organization.der for the identity, click Save
  • Then, click the Export button. We will use those files for cfgutil automation tool.

Activate Supervised Mode for iOS devices

To activate your iOS device with the supervised mode, you need to make sure that the iCloud account has been signed out.

  • Connect your iOS devices to a Mac
  • Select the device and click Prepare
  • In the Prepare Devices view, choose Manual Configuration and select the checkbox Supervise devices
  • In the Enroll in MDM Server view, select Do not enroll in MDM
  • In the Assign to Organization view, select your Organization
  • In the Configure iOS Setup Assistant view, select Don’t show any of these steps
  • Click “Prepare” button (If the confirm popup is displayed, click on the “Erase” button.)
  • After the device is prepared, it is moved to the “Supervised” tab.

Configure Passcode function on Kobiton Desktop app

  • Copy two generated files Organization .crt & Organization.der and move them into this folder: ~/Library/Application\ Support/Kobiton/
  • Create config file in the folder ~/Library/Application\ Support/Kobiton/devices/${udid} (We can get UDID of the device in the Info tab.)
  • Add data for config file

{“unlockPasscodeEnabled”: true}

  • Unplug & plug the device again
  • Register the device and start your testing
  • Note: The passcode is generated by the Kobiton system and is backed up in the same folder.

Interested in Learning More?

Subscribe today to stay informed and get regular updates from Kobiton

Ready to accelerate delivery of
your mobile apps?

Request a Demo