getCodename is a Python script designed to assist in the enumeration phase during red teaming engagements. The tool searches for the corresponding distro codename on Launchpad given the OpenSSH version string provided as argument or from a Nmap output file in normal format (-oN). This can help in identifying potential vulnerabilities, dockerized environments or version-specific features.
- Extract SSH Version:: Automatically extract the OpenSSH version from Nmap output.
- Search Launchpad: Query Launchpad for Distro release information using the extracted or provided SSH version.
- Identify Codename: Retrieve the Distro codename associated with the specific OpenSSH version.
Clone the repository:
git clone https://github.com/0xv01d/getCodename.git
cd getCodenameInstall the required Python packages:
pip install -r requirements.txtRun the script with Python, using either the Nmap output file or the SSH version string as input.
python getCodename.py [OPTIONS]...- -f, --file : Path to a file containing Nmap output.
- -s, --ssh-version : SSH version string to search (e.g., "OpenSSH_8.9p1 Ubuntu 3ubuntu0.6").
- -n, --num-results : Number of Launchpad search results to retrieve (default is 1).
- -h, --help : Show this help message and exit.
Extract SSH version from Nmap output:
python getCodename.py -f nmap_output.txtUse a specific SSH version string:
python getCodename.py -s "OpenSSH_8.9p1 Ubuntu 3ubuntu0.6"Specify the number of search results:
python getCodename.py -f nmap_output.txt -n 3Note: For best results, the SSH version string should be in the format: "8.9p1 Ubuntu 3ubuntu0.6".
This project is licensed under the MIT License. See the LICENSE file for more details.
Contributions are welcome, fork this repository and submit a pull request for any improvements.
Author 0xv01d