diff --git a/content/cloudflare-one/identity/devices/warp-client-checks/os-version.md b/content/cloudflare-one/identity/devices/warp-client-checks/os-version.md index 7e683999cc7529d953b24b9733c20d1f7129645e..828324f78d349d3a8af6f4dae8344aa59d806058 100644 --- a/content/cloudflare-one/identity/devices/warp-client-checks/os-version.md +++ b/content/cloudflare-one/identity/devices/warp-client-checks/os-version.md @@ -17,7 +17,7 @@ weight: 8 </div> </details> -The OS Version device posture attribute checks whether the version of a device’s operating system matches, is greater than or lesser than the configured value. The version must be specified as a valid Semver (for example, `1.2.0`). +The OS Version device posture attribute checks whether the version of a device’s operating system matches, is greater than or lesser than the configured value. ## Enable the OS version check @@ -25,15 +25,14 @@ The OS Version device posture attribute checks whether the version of a device 2. Scroll down to **WARP client checks** and select **Add new**. 3. Select **OS version**. 4. Configure the **Operating system**, **Operator**, and **Value** fields to specify the OS version you want devices to match. -5. (Optional) Configure Linux operating system distro **Name** and **Revision** field(s) to specify the version you want devices to match. {{<Aside type="note">}} - -Ensure the version is entered as a valid `x.x.x` Semver. If your device is running OS version `x.x`, you must enter `x.x.0`. - +The OS version must be specified as a valid Semver. For example, if your device is running OS version `1.2`, you must enter `1.2.0`. {{</Aside>}} -5. Select **Save**. +5. (Optional) Configure Linux operating system **Distro name** and **Distro revision** to specify the version you want devices to match. The distro version matches with an equal-to operator (==), regardless of the **Operator** setting. + +6. Select **Save**. Next, [verify](/cloudflare-one/identity/devices/#2-verify-device-posture-checks) that the OS version check is returning the expected results. @@ -46,8 +45,8 @@ Operating systems display version numbers in different ways. This section covers 1. Open a terminal window. 1. Use the `defaults` command to check for the value of `SystemVersionStampAsString`. - ```txt - defaults read loginwindow SystemVersionStampAsString + ```sh + $ defaults read loginwindow SystemVersionStampAsString ``` ### On Windows @@ -55,45 +54,36 @@ Operating systems display version numbers in different ways. This section covers 1. Open a Powershell window. 1. Use the `Get-CimInstance` command to get the version property of the `Win32_OperatingSystem` class. - ```txt + ```bash (Get-CimInstance Win32_OperatingSystem).version ``` ### On Linux -Linux currently relies on the system Kernel version instead of a specific distro version. For the OS version check to work, the kernel version must be converted to a valid SemVer. +#### OS version + +The Linux OS version check returns the system kernel version. For the OS version check to work, the kernel version must be converted to a valid SemVer. 1. Open a Terminal window. -1. Run the `uname -r` command to get the complete version. +2. Run the `uname -r` command to get the complete version. - ```bash - uname -r + ```sh + $ uname -r ``` -1. The valid SemVer would be the first 3 whole numbers of the output you obtain in the previous step. For instance, if the command above returned `5.14.0-25.el9.x86_64`, the valid SemVer would be `5.14.0`. - -Determining **Name** and **Revision**: - -{{<Aside type="note">}} +3. The valid SemVer would be the first 3 whole numbers of the output you obtain in the previous step. For instance, if the command above returned `5.14.0-25.el9.x86_64`, the valid SemVer would be `5.14.0`. -Note that the **Revision** field matches with an equal-to operator (==) rather than greater or lesser than (> or <) operator. +#### Distro version -{{</Aside>}} +The WARP client reads **Distro name** and **Distro revision** from the `/etc/os-release` file. The name comes from the **ID** field, and the revision comes from the **VERSION_ID** field. -The following parameters are obtained via the `/etc/os-release` file. **Name** comes from the **ID** field, and **Revision** comes from the **VERSION_ID** field. +To determine the distro version on your device: 1. Open a Terminal window. -1. Run the `cat /etc/os-release | grep "ID"` command to get OS identification fields that contain `ID`. +2. Get the OS identification fields that contain `ID`: - ```bash - cat /etc/os-release | grep "ID" + ```sh + $ cat /etc/os-release | grep "ID" ``` -1. If the output of the above command contained the fields `ID=ubuntu` and `VERSION_ID=22.04`, our **Name** value would be `ubuntu` and **Revision** would be `22.04`. - - - - - - - +3. If the output of the above command contained `ID=ubuntu` and `VERSION_ID=22.04`, **Distro name** would be `ubuntu` and **Distro revision** would be `22.04`. The WARP client will check these strings for an exact match.