Python platform Module
PCAP objective 1.4 is discover host platform properties using the platform module, and it is the smallest objective in either syllabus - a dozen functions that each return a string. The two things worth knowing are that processor() frequently returns an empty string, and that the python_* functions describe the interpreter rather than the machine, which is where a question can be built.
Modules and Packages Guide 7 of 25 Beginner
- OSUbuntu 26.04 LTS
- Python3.14.4
- pip25.1.1
- TimeAbout 12 min
platform.linux_distribution() was removed in Python 3.8 and is not on the syllabus; material that uses it is very old. platform.java_ver() was removed in 3.13. Everything the objective names is present and unchanged.
| Server Name | IP Address | OS | Roles | CPU | RAM | HDD |
|---|---|---|---|---|---|---|
| RUNNER01 | 192.168.0.27 | Ubuntu 26.04 LTS | Python 3.14.4 - the only machine this path needs | 2 Core | 4 GB | 50 GB |
This guide includes
Use this for the host-properties objective. This matters because one of the functions the objective names usually returns an empty string on Linux - and the exam asks about that one.
- calling every function the objective names
- meeting the one that usually returns nothing at all
- using
platform()and its two arguments - reading what the
python_functions say about the interpreter - using
uname, and finding the function that is gone
Before you start
- guide 4 -
import platform. - Nothing else. This is the shortest guide in the path.
-
Every function the objective names
-
The function that returns nothing
-
platform() and its two arguments
-
The python_ functions describe the interpreter
-
uname, and the function that is gone
-
What the exam does with this objective