Maxime Betirac Documentation

website·Indexed 31 days ago

https://docs.maximebetirac.fr

A personal knowledge base and technical reference covering Linux administration (Ansible, Docker, KVM, Wireguard, Apache, Certbot, IPtables), Cybersecurity (OSINT, Forensics, Steganography, Pentesting, OSCP, CTFs), and Windows tips including PowerShell.

Tokens
8.6K
Snippets
56
Records
75
Agent score
56%

What's inside Maxime Betirac Docs

  1. Use Velociraptor for endpoint visibility and collection

    Velociraptor is an open-source tool used for endpoint visibility and digital forensic collection across a network of hosts.
    # Visit the official repository for installation and usage
    # https://github.com/Velocidex/velociraptor
  2. Digital Forensics fundamentals and chain of custody

    Digital Forensics (Investigations Numériques) focuses on collecting evidence while ensuring its integrity and traceability through a 'chain of custody'. To avoid altering original evidence, a 'Master' copy of the original medium must be created. All subsequent analysis should be performed on copies of the Master, and the original medium must be sealed once the Master is produced.
  3. Perform post-exploitation cleanup and reporting

    Post-exploitation requires cleaning up all traces of the test, including removing backdoors and temporary accounts. The final stage is reporting, which includes a hot debrief with the client and a formal report.

    Reporting Tools

    • PeTeReport: Report generation
    • XMind: Creating attack path MindMaps for executives/CISOs
  4. Create a non-logged root shell backdoor

    To create a root shell that does not leave traces in logs, you must have existing root access to the server. This involves copying the bash binary and setting the SUID bit.
    cp /bin/bash rootShell
    sudo chown root:root rootShell
    sudo chmod 6777 rootShell
    ./rootShell
  5. Analyze vulnerabilities and model threats

    Threat modeling and vulnerability analysis are often grouped together. Use automated scanners to identify potential security flaws.

    Vulnerability Analysis Tools

    • nessus: Comprehensive scanner (limited free version)
    • openvas - GVM: Open-source containerized scanner
  6. Use steganography tools for image analysis and CTF challenges

    Depending on the complexity and format of the image, use the following tools for steganography analysis:

    • Aperi'Solv: A highly effective online application for solving simple steganography challenges.
    • Forensically: An online tool used to modify image appearance and perform forensic analysis.
    • Zsteg: A specialized tool for analyzing PNG image formats.
    # Example: Installing zsteg (Ruby gem)
    gem install zsteg
    
    # Usage for PNG files
    zsteg image.png
  7. Create a MySQL database and user with privileges

    Standard sequence for creating a new database, assigning a user with a password, and granting all privileges on that specific database.
    CREATE DATABASE dbname;
    CREATE USER 'utilisateur'@'localhost' IDENTIFIED BY 'password';
    GRANT ALL PRIVILEGES ON dbname.* TO 'utilisateur'@'localhost';
    FLUSH PRIVILEGES;
  8. Set up network pivoting with Ligolo-ng

    Ligolo-ng is used for pivoting when a target machine does not have a direct route to the Kali machine and traditional tools like Chisel fail. It requires a proxy binary on the Kali machine and an agent binary on the compromised pivot machine (e.g., a Windows machine). The proxy handles the routing, allowing the attacker to use tools from Kali against targets behind the pivot.
    # On Kali: Create and enable the ligolo virtual interface
    sudo ip tuntap add user kali mode tun ligolo
    sudo ip link set ligolo up
    
    # On Kali: Add the route to the target network via the ligolo interface
    sudo ip route add 10.10.x.x/24 dev ligolo
    
    # On Kali: Start the proxy
    ./proxy -selfcert
  9. Install Volatility V3

    Volatility V3 is installed from its GitHub repository. It requires Python 3 and specific dependencies defined in requirements-minimal.txt.
    git clone https://github.com/volatilityfoundation/volatility3.git && cd volatility3
    pip3 install -r requirements-minimal.txt
    python3 setup.py build 
    python3 setup.py install
  10. Follow the PTES methodology for internal penetration testing

    Internal penetration tests should follow the Penetration Testing Execution Standard (PTES), which consists of seven primary stages: Rules of Engagement, Information Gathering, Threat Modeling, Vulnerability Analysis, Exploitation, Post-Exploitation, and Reporting.
  11. Conduct GeoINT (Geospatial Intelligence) analysis

    Use these tools for mapping, location analysis, and environmental data:

    • OverPass Turbo: A powerful web-based data filtering tool for OpenStreetMap used for complex and massive geographic searches.
    • SunCalc: Interactive map showing sun movement and sunlight phases for a specific location and time.
    • Smappen: A simple and fast mapping application.
    • GeoInt-Localisator: A Python 3 tool using Selenium to calculate distances between two unknown generic locations (e.g., stores, supermarkets).
    • Felt: A tool for rich and readable cartographic data presentation.
  12. Establish Rules of Engagement for penetration tests

    Before starting a penetration test, it is mandatory to have the client sign the following documents:

    • A penetration test authorization form
    • A Non-Disclosure Agreement (NDA)