the ongoing struggle: man vs machine
Category Archives: Sys Admin
29/09/2015Posted by on
The recommended way to configure an enterprise wireless network is with certificates rather than a shared passphrase. This allows you to issue a certificate to each wireless device, and should a device be lost, revoking the certificate is all that is required to prevent access.
Searching the internet reveals that many guides focus on using the iPhone Configuration Utility to install a certificate and wireless profile on IOS devices as, or using MDM, as the only possible ways to enable apple devices to participate in this network. What I seek to outline is a 3rd way that relies on neither of these methods.
The reason for this guide is that the iPhone Configuration Utility is end of life, and will not work with IOS 8 and above. It has been replaced by Apple Configurator, which is an app only available on MacOS. Purchasing a Mac just to configure iPads is not an option for me.
I will details all steps to get a non-domain joined device (weather it be a PC, Tablet or Phone) to join the wireless network.
This guide assumes that you already have a functional WPA2-Enterprise EAP-TLS Wi-Fi network, NAP server and Certificate Authority. This network should already be functional with domain-joined PCs.
Create A Certificate Template
Stage 1 of this process is to create an appropriate certificate template, and enable the template on our Certification Authority.
- On your certificate server, open a blank MMC console, and add the certificate templates, and certification authority snap-ins.
- Under the Certificate Templates Node, Right Click the “Computer” template and click “Duplicate Template”
- Select “Windows Server 2003 Enterprise” As the template version, and click OK.
- On the General Tab, give the template a display name, template name, and set a validity period
- On the Request Handling tab, Set the Purpose to Signature and Encryption, set a minimum key size of 2048, and tick on the “Allow private key to be exported” checkbox
- (CRITICAL) On the Subject Name tab, check the option to “Supply in the request”, as shown below.
- On the Issuance Requirements tab, check the checkbox for “CA certificate manager approval”. This ensures that an administrator is involved in approving the issue of a certificate to non-domain (i.e. non-trusted) devices.
- Finally, on the Security tab, ensure an appropriate administrative user has rights to read, write and enroll certificates based on this template. Click Ok.
- Now we need to enable the certificate template on our Certificate Authority. Navigate to Certification Authority>Certificate Templates. Right click the node, and select New>Certificate Template to Issue.
- Select the template you created in previous steps and click ok.
Create Certificate Request
Stage two of this process is to request a certificate. I am doing this from my own domain-joined Windows 7 PC, however it may be better practice to have a workstation dedicated to this task. (Note that I have certificate auto-enrolment enabled for my domain, so my PC will automatically enrol certificates issued to it).
- Open up a blank MMC console as administrator (This should be the administrator you defined earlier on your certificate template). Add the Certificates (local computer) snap-in.
- Expand Certificates>Personal
- Right-Click “Personal”>All Tasks>Request New Certificate
- Click Next until you arrive at the Request Certificates Screen
- Check the mobile device template, and click properties.
- On the Subject Tab, fill out the certificate details. Common Name is required by the system, whilst other fields are optional, however I recommend you fill in at least these fields.
(e.g. username_IOSPhone1 for BYOD or asset number for corporate owned devices)
Note, the common name cannot be longer than a NetBIOS name (20 characters)
Organisational Unit (I.e. department)
- Click Ok, then enrol.
- The final screen shows that enrolment is pending. This is because on the template, we selected that approval was required before issuance. Click Finish.
On your Certification Authority Server, open up the Certification Authority Console (as administrator) and navigate to “Pending Requests”. Issue the certificate from the right click menu (Ensure that you have the correct certificate request).
Export Certificates with Key and Without Key
- Return to the certificates console on your local computer. Right-click on the Certificates>Local Computer root node, and choose “All tasks>Automatically enrol and retrieve certificates. Complete the wizard. (This works because certificate auto-enrolment is enabled in my domain).
- Navigate to Personal>Certificates. You will see your newly issued certificate.
- Right-click the new certificate, and select All Tasks>Export.
- Follow the wizard, choosing to export the private key, and include all certificates in the certification path. You will need to set a password for the certificates.
- Export a second copy of the certificate, this time with no key.
Map Certificate to an Account
Note: The normal authentication process involves the computer presenting the certificate (Common Name) to the Network Policy Server (NPS), which in turn will check if the computer account is enabled in AD DS, and that the certificate is valid. Because we are issuing computer certificates, logic would follow that we need to map the computer certificate to a computer account in active directory.
Devices such as iPads behave differently, where they treat all certificates installed as a user certificate, hence when passing the subject name to the NPS server, NPS will look for a user object in AD DS rather than a computer object, causing the authentication request to fail. When this occurs, you will see logs in the NPS server security event log. Keep in mind that devices from different vendors may behave differently, so watch out for this issue.
- Open up Active Directory and create a dummy user account. This account must have a username that matches the common name on the certificate. Passwords and other options do not matter for this purpose.
- If your NPS server has a group which contains authorised clients, add this account to that group.
- Select the new account, and choose Action>Name Mappings
- Add the certificate you exported without the key, and click ok.
Configure the IOS Device
Note: These instructions have only been tested on an IPAD 3 running IOS 9.0.1. Your mileage may vary.
Now to the heart of the issue. The previous steps are only an overview of the process to prepare a certificate for a non-domain joined device, and should be acceptable for most devices for WPA2-Enterprise EAP-TLS authentication. What follows are the steps to perform on the iPad (or iPhone) to enrol the certificate on the device, and use the certificate as the credentials to join the wireless network.
- Transmit the certificate that was exported (the version with the key) in any way possible to the device. Methods can include cloud storage, email etc. It’s entirely up to you. Just be cautious, as this file has the private key included. This needs to be protected, even though the key is protected by a password you set when you exported the certificate.
- Open the certificate file on the device. IOS will recognise the file as a certificate file, and begin the import process. Tap install.
- Tap install again.
- Tap install again.
- Enter the password to unlock the private key.
- Click Done. Your Certificate has now been imported into an IOS identity profile, without the aid of external tools.
- Finally, lets join the wireless network, with some minor changes to the usual process on IOS. Tap Wi-Fi, and tap on the network you want to join (being your EAP-TLS network, not some other passphrase based network).
- Notice that you are prompted for a username and password. Change the mode to EAP-TLS (Why does automatic not work…….?)
- The prompt has changed to username and identity. Username is optional, and we will leave it blank. Tap “Identity
- A list of installed identities is provided (I only have one). Tap the identity to use for the connection, which places a blue tick next to it.
- Tap “Enter Password” to return to the main Wi-Fi screen, then tap “Done”.
- You will now be asked if you trust the NPS server Certificate. Tap “Trust”.
- You are now connected.
A Quick Note about Revocation
Depending on how your Certificate Authority is configured, and the cache timeouts for Certificate Revocation List checking, there are two ways that can be used to prevent a device from connecting to the wireless network.
1. Revoke the certificate. – This is the most reliable method, as it ensures the certificate cannot be used again. The downside is that this can take a long time to take effect, as the various cache timeouts and CRL updates can take a long time.
2. Disable or delete the computer or user account that the certificate is mapped to – This takes effect immediately, however the certificate is still valid, and if used for other purposes, can still authenticate.
I recommend you perform both of these steps, just to be sure. Neither of these steps will kick an active Wi-Fi connection off the network, but they prevent a re-connection attempt.
I hope you find this helpful.
Connecting iPads to an Enterprise Wireless 802.1x Network Using Certificates and Network Device Enrollment Services (NDES) – http://blogs.technet.com/b/pki/archive/2012/02/27/ndes-and-ipads.aspx
Certificates and Exporting Private Key – https://social.technet.microsoft.com/forums/systemcenter/en-US/b24c4a4f-7b4c-42d3-b23f-58fcc18ddb80/certificates-and-exporting-private-key
27/10/2014Posted by on
This guide will lead you through the basic steps to deploy Google Chrome with group policy. It is based on v38, which at the time of writing is the current release. To follow this guide, you should already be familiar with Group Policy in general.
As with any task, first clearly define the objectives you want to achieve before starting. Your objectives will no doubt be different, so this guide should be a general reference only.
1. Install Google Chrome 64bit edition for all users of selected Windows 7 PCs. For our purpose the computers are all in the active directory organisational unit “Computers – Windows 7”.
2. Set home page to a specific address.
3. Reduce automatic update frequency.
Task 1 – Obtain the appropriate Files
- Download the 64bit msi package of the enterprise Google chrome that Google helpfully provide. It can be located at https://www.google.com/intl/en/chrome/business/browser/admin/
- Download the adm and admx group policy templates from https://support.google.com/chrome/a/answer/187202
- Download the Google Update adm group policy template from https://support.google.com/installer/answer/146164
Task 2 – Copy MSI file to the deployment share.
- Copy the downloaded .msi file to a deployment share that client computers have read access to.
Task 3 – Create a new GPO to deploy the software and settings.
- Open group policy management console on a domain controller, and create a new policy. Give it a descriptive name that will still retain some meaning to you and your colleagues in 6 months time.
- Edit the newly created policy (Right-click>Edit) and navigate to the Computer Configuration>Policies>Software Settings>Software Installation node.
- In the right-hand pane, right click and select New>Package
- Navigate to the package file you earlier placed in the deployment share, and click ok.
- Select Advanced for the deployment method and click Ok.
- Enter a name for the package. I like to put both the architecture and version number in the package name, but it is up to you really. Note that this is the name that will appear in the installed program list on the client computers. I like to put the word “Deployed” in the name to distinguish the group policy installs from the manual installs.
- No further options are required to be set, however depending on your environment, you may wish to set some further options. I always set “Ignore language when deploying this package” which is under Deployment>advanced. Once done, click ok.
- The install will now install to any PC’s that are covered by the policy you created. If you are testing, you may wish to run the command “gpupdate /force /boot” on your test PC to force an immediate deployment.
- Close the Group Policy Management Editor before continuing.
Task 4 – Customise via Group Policy
In my case I need to import the .admx template files into my Windows 2008 R2 central store. Your group policy setup may be different. The below paths are for my environment, and your environment will be different.
- Extract the policy templates archive.
- Copy Chrome.admx to D:\ADDS\Sysvol\sysvol\xxxxxx\Policies\PolicyDefinitions\
- Copy the language specific adml files for your required languages to the central store. i.e. the EN-GB files to D:\ADDS\Sysvol\sysvol\xxxxxx\Policies\PolicyDefinitions\EN-GB\
- Open Group Policy Management Editor and edit the policy you created earlier. When you expand Policies>Administrative Templates>Google in both computer configuration and User Configuration, you will see the new settings that can be applied.
- In our case, we want to change the default home page, and not allow the user to override this. Navigate to the “Computer Configuration>Policies>Administrative Templates>Google>Google Chrome>Home page and set the”Configure Home Page URL” setting.
Note that is we had desired users have the ability to override, and wanted to set a default, we could have configured the same setting under the “Google Chrome – Default Settings (users can override)” node.
- I will also set the “Use New Tab Page as Homepage” option to disabled, to prevent users from changing the homepage behaviour.
- This will now load the homepage you have just configured when the home button is clicked. The default startup action for Chrome 38 doesn’t open the homepage, but a new tab. Navigate to Google Chrome>Startup pages and change both the action on startup (Open a list of URLs) and URLs to open on startup settings.
Configure Update Frequency
Chrome will be updated via the Google Update software that is installed alongside Chrome, even for users without admin rights. To manage this software, we need to use the Google update adm template that we downloaded earlier.
- Copy the Google update adm template file to a location on the domain controller.
- Within the GPME, right-click the administrative templates node, and select add/remove templates.
- Add in the Google update adm template, and click close.
- You now have the ability to manage Google update.
- Navigate to the “Google update>preferences” node, and set the auto-update check period override to the desired setting. I have set the number of minutes to 10080 to enable a weekly update.
Now you should have a working setup. I would recommend you review the documents located below in the resources section, and the other available group policy settings to identify further opportunities to set default settings as appropriate.
Set up Chrome for Work
Set chrome policies for devices
Google Update for Enterprise
17/01/2014Posted by on
This article will go through the simple steps required to install the ESXi Vmware tools onto a debian 7 guest.
1. The first step is to install debian’s compiling tools and kernel headers for the current running kernel.
aptitude install build-essential
aptitude install linux-headers-$(uname -r)
2. Mount the VMware tools CD by going to the guest menu and selecting “Install VMware tools”.
3. Mount the CD
mount /dev/sr0 /mnt/
4. Extract the archive to the local tmp folder.
tar xfzv /mnt/VMwareTools-9.0.5-1065307.tar.gz –C /tmp
5. Change to the extracted directory
6. Run the script to build the needed kernel modules.
7. The script will ask you various questions as the install progresses. Just press enter to accept the default choices, unless you desire to change it.
8. Reboot the virtual machine and check that the vmware tools are now listed as running by vmware.
28/12/2013Posted by on
This is actually not the case. Microsoft have just made the feature difficult to find.
To find this option, you must search for “file history” from the start menu (previously known as the metro interface) and run it. Alternatively, you can find the file history program from the control panel in desktop mode.
Once the file history program loads, you will see the “System Image Backup” link at the bottom left of the screen. This gives access to the same backup interface that was available in Windows 7. No 3rd party software and no powershell scripts are required.
09/11/2012Posted by on
We all know life is busy for us system administrators. Keeping servers updated is generally a good security practice, but is often overlooked due to more pressing concerns. This can often be especially true for the trusty linux servers that sit in the corner and never cause a problem.
This short tutorial will guide you through setting up the apticron tool to alert you when updates are available for debian.
It relies on the server being able to send emails, so ensure that this is possible through exim, postfix or sendmail first.
1. Open terminal as root
2. run command apt-get install apticron
3. Edit the configuration file with nano.
4. Change EMAIL=”root” to a valid email address. Note that quotes must remain around the email address.
5. Press CTRL-O to save, then CTRL-X to quit nano.
All done. You will now receive a daily email with the required updates.
08/08/2012Posted by on
Today I received a notification from the System Administrators Guild of Australia (SAGE-AU) forum that Microsoft was releasing a large number of their Microsoft Press Books for free, and I thought I would share this with the wider community.
Microsoft’s Director or Partner Experience, Eric Ligman, has posted links to a large number of free eBooks and resources for Developers and System Administrators.
I encourage everyone to check it out.