EvilZone

Programming and Scripting => Beginner's Corner => : jpHernandez January 09, 2015, 11:56:19 PM

: [BEGINNERS] Batch Script, Collecting Information from Local Machine
: jpHernandez January 09, 2015, 11:56:19 PM
This code collects information from local machine and saves it to a text file called "info.txt"

:
@echo off
title info
hostname > info.txt
date /t >> info.txt
time /t >> info.txt
echo + Dumping user accounts...
net user >> info.txt
echo Done
echo + Dumping system information...
systeminfo >> info.txt
echo Done
echo + Dumping network status...
netstat -ano >> info.txt
echo Done
echo + Dumping network shares...
net share >> info.txt
echo Done
echo + Dumping computers on LAN...
net view >> info.txt
echo Done
echo + Dumping wireless networks on range...
netsh wlan show networks >> info.txt
echo Done
echo + Dumping network accounts info...
net accounts >> info.txt
echo Done
echo + Dumping workstation config...
net config workstation >> info.txt
echo Done
echo + Dumping localgroups...
net localgroup >> info.txt
echo Done
echo + Dumping administrators...
net localgroup administrators >> info.txt
echo Done
echo + Dumping running tasks...
tasklist >> info.txt
echo Done
echo + Dumping installed softwares...
reg query HKLM\Software >> info.txt
reg query HKCU\Software >> info.txt
echo Done
echo. >> info.txt
echo End of File >> info.txt

Cheers,
jph ;D