Friday, June 21, 2013

Install Wireshark in Ubuntu Desktop 12.10

Install Wireshark in Ubuntu Desktop 12.10

1. sudo apt-get install wireshark
2. sudo dpkg-reconfigure wireshark-common
3. sudo usermod -a -G wireshark $USER
4. sudo reboot


Tuesday, June 11, 2013

Play Music Via Command Line - with mplayer

Play Music Via Command Line - with mplayer

1. Install mplayer in Ubuntu Desktop by issue command
sudo apt-get install mplayer
2. Go to the music folder and start to play 
mplayer  file001.mp3
or
mplayer file002.mp4

or you can play music 
mplayer *.mp3
mplayer *.mp4

Common shortcut:
Q = Quit
P = Pause
Up arrow = Jump forward in file more
Right arrow = Jump forward in file less
Down arrow = Jump back in file more
Left arrow = Jump back in file less
) = Volume up
( = Volume down
M = Volume mute
F = Full screen view
O = On-screen display
V = Toggle subtitles in video


Friday, June 7, 2013

Recover Delete Files

Recover Delete Files in Ubuntu Desktop

1. Install
sudo apt-get install scalpel

2. Edit file configure
sudo vi /etc/scalpel/scalpel.conf

and uncomment before the file extension that we want to RECOVER.

3. Run the command to recover.
sudo scalpel /dev/sda6 -o output

4. See the result in folder output.

Monday, May 27, 2013

Bash Scripts

Bash Scripts

Install the latest MetasPloit in Ubuntu Desktop

Install the latest MetasPloit in Ubuntu Desktop

Install the latest MetasPloit in Ubuntu:

1. Download Metasploit framework from :
wget http://downloads.metasploit.com/data/releases/metasploit-latest-linux-installer.run

2. Make installer executable:
chmod +x metasploit-latest-linux-xxx-installer.run

3. Run installer:
./metasploit-latest-linux-xxx-installer.run
4. Follow setup wizard to complete Metasploit installation.

5. To get latest Metasploit updates execute:
sudo msfupdate
6. Run Metasploit:
msfconsole

Command - Find

Command - find


find  a folder name .svn in a folder/subfolder and delete all
# rm -rf `find . -type d -name .svn`
find a file with extension .sh .Sh .sH with -iname
# find -iname *.SH 
find file with extension .tar.gz
# fine -name  *.tar.gz 

Command - SED

Command - SED


Insert the # sign from a specific line to the last
# sed -i '4,$ s/^/#/' file-name.sh
Add special sign with sed
# sed -i -e 's/$/ \&>> $STATUS/g' file-name.sh
Add Variable with sed
# sed -i 's/&> $STATUS//g' file-name.sh

Web tools

http://rubular.com/
http://rubyxp.com/

https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions?redirectlocale=en-US&redirectslug=JavaScript%2FGuide%2FRegular_Expressions