Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- GRADE 2 SESSION 17
- ===================
- Introduction to System Hardening
- ================================
- System hardening is a auditing process in which we try to scan and check each and every aspect of security from settings to updated versions of system softwares which may or may not lead to a system compromisation.
- To reduce the surface of vulnerability.
- Windows: Critical Systems with OS (Servers 2008 onwards)
- Windows: Non Critical Systems with OS (Simple OS inhouse computers)
- Windows: Hardware Devices in scope (CCTV Camera with Windows Mobile OS inside it etc.)
- System Hardening is a very critical audit process in which every aspect of security is being considered to be a serious issue, majority of the comapnies are maintaining the system security with AD control framework. Hence no one audit a single pc manualy which is the gap which we fullfil as an auditor on the client site.
- Sample Checklist of Windows 7 : Control List
- Good Firewall > Inbound and Outbound Rules.
- Antivirus
- Disable Autorun
- Disable USB
- Never download or surf on unknown source
- msconfig.msc
- secpol.msc
- gpedit.msc
- regedit.exe
- - Setting SEcurity Policies using secpol.msc and gpedit.msc
- - Banning malicious hamful extensions such as (.bat) for Windows using regedit.exe
- - Checking Startup and Persistence Process using msconfig.msc
- ISO 27001 Compliance - Bible for system auditing and system hardening(ISMS - INFORMATION SECURITY MANAGEMENT SYSTEM)
- In the whole ISO series, ISO 27001 and 27002 is considered to be the most widely and bestly used compliance.
- CSO
- CISO
- Lead Auditors
- - Perimeter Security : Perimeter security refers to natural barriers or built fortifications to either keep intruders out or to keep captives contained within the area the boundary surrounds.
- Basic Security Configurations : Checking the outdated softwares in the environment, checking the old hardware having old firmware application running, applications running with vulnerable version. etc.
- Automated Security Analyzers
- -> Script (For Example: Sub Domain Finder : GITHub)
- -> nmap
- -> SPARTA
- Linux Based System Hardening
- ----------------------------
- - Lynis
- Lynis - Security auditing and hardening tool, for UNIX-based systems.
- Lynis is a security auditing for UNIX derivatives like Linux, macOS, BSD, and others. It performs an in-depth security scan and runs on the system itself. The primary goal is to test security defenses and provide tips for further system hardening. It will also scan for general system information, vulnerable software packages, and possible configuration issues. Lynis was commonly used by people in the "blue team" to assess the security defenses of their systems. Nowadays, penetration testers also have Lynis in their toolkit.
- Goals
- ======
- The main goals are:
- --------------------
- Automated security auditing
- Compliance testing (e.g. ISO27001, PCI-DSS, HIPAA)
- Vulnerability detection
- The software (also) assists with:
- ---------------------------------
- Configuration management
- Software patch management
- System hardening
- Penetration testing
- Intrusion detection
- Typical users of the software:
- ------------------------------
- System administrators
- Auditors
- Security officers
- Security professionals
- Installation
- ============
- Git
- Clone or download the project files (no compilation nor installation is required) ;
- git clone https://github.com/CISOfy/lynis
- Execute:
- ./lynis audit system
- --------------------------------------------------------------------------
- Bash Scripting
- ==============
- Creating a tool like Netdiscover which shows active hosts in a network.
- File name : searchip.sh
- - ping 192.168.0.1, ping 192.168.0.2 etc
- - ping -c 1 192.168.0.1, ping -c 1 192.168.0.2 etc
- - ping -c 1 192.168.0.1 | grep "64 bytes", ping -c 1 192.168.0.2 | grep "64 bytes" etc.
- - ping -c 1 192.168.0.1 | grep "64 bytes" | cut -d " " -f4, ping -c 1 192.168.0.2 | grep "64 bytes" | cut -d " " -f4 etc.
- - ping -c 1 192.168.0.1 | grep "64 bytes" | cut -d " " -f4 | cut -d ":" -f1 , ping -c 1 192.168.0.2 | grep "64 bytes" | cut -d " " -f4 | cut -d ":" -f1 etc.
- - Looping statement
- for i in $(seq 1 255);
- do
- ping -c 1 192.168.0.$i | grep "64 bytes" | cut -d " " -f4 | cut -d ":" -f1
- done
- ------------------------------------------------------------------------------------
Advertisement
Add Comment
Please, Sign In to add comment