Detecting and responding to network intrusions involves using various Command Prompt (CMD) techniques. Below is a guide on how to use CMD commands to identify and respond to potential security incidents.
Audit policy settings help trace user activities and security incidents.
auditpol /get /category:*
Security event logs provide insights into recent security events.
wevtutil qe security /f:text /c:10 /rd:true
Network traffic monitoring can reveal abnormal patterns indicative of intrusions.
netsh trace start capture=yes
netsh trace stop
Disabling unnecessary services can reduce the potential attack surface.
sc config remoteRegistry start=disabled
Identifying open ports can help spot unauthorized access attempts.
netstat -an
Identifying executables associated with active connections can help find malicious software.
netstat -b
Examining the routing table can reveal unauthorized changes in network routing.
route print
Reviewing quarantined items can provide insights into detected threats.
"%ProgramFiles%\Windows Defender\mpcmdrun.exe" -restore -listall
Shadow tasks may be created by attackers to maintain persistence.
schtasks /query /fo LIST /v
schtasks /delete /tn "TaskName" /f
Checking running processes can help detect unauthorized or suspicious activities.
tasklist
taskkill /PID ProcessID
Scanning system files can identify and repair unauthorized modifications.
sfc /scannow
Listing user accounts helps detect unauthorized accounts created by attackers.
net user
net user username