You are on page 1of 3

Laboratório de Análise de Vulnerabilidades

Ambientação

1. Configurando endereçamento IP e DNS

a) Estático

root@bt:~# ifconfig eth0 172.16.49.165/24


root@bt:~# route add default gw 172.16.49.2

b) Dinâmico

root@bt:~# dhclient eth0


There is already a pid file /var/run/dhclient.pid with pid 8683
killed old client process, removed PID file
Internet Systems Consortium DHCP Client V3.1.3
Copyright 2004-2009 Internet Systems Consortium.
All rights reserved.
For info, please visit https://www.isc.org/software/dhcp/

Listening on LPF/eth0/00:0c:29:3b:af:f0
Sending on LPF/eth0/00:0c:29:3b:af:f0
Sending on Socket/fallback
DHCPREQUEST of 172.16.49.165 on eth0 to 255.255.255.255 port 67
DHCPACK of 172.16.49.165 from 172.16.49.254
bound to 172.16.49.165 -- renewal in 872 seconds.
root@bt:~#

c) DNS

root@bt:~# echo nameserver 8.8.8.8 >> /etc/resolv.conf


root@bt:~#
2. Identificando Serviços (TCP e UDP)

root@bt:~# netstat -natp


Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 127.0.0.1:7337 0.0.0.0:* LISTEN 1058/postgres
tcp6 0 0 ::1:7337 :::* LISTEN 1058/postgres
root@bt:~# netstat -naup
Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
udp 0 0 0.0.0.0:68 0.0.0.0:* 1928/dhclient
udp6 0 0 ::1:32948 ::1:32948 ESTABLISHED 1058/postgres
root@bt:~#

a) Iniciando Serviços TCP (SSH e Apache Web Server)

root@bt:~# /etc/init.d/ssh start


Rather than invoking init scripts through /etc/init.d, use the service(8)
utility, e.g. service ssh start

Since the script you are attempting to invoke has been converted to an
Upstart job, you may also use the start(8) utility, e.g. start ssh
ssh start/running, process 12144
root@bt:~# /etc/init.d/apache2 start
* Starting web server apache2 [ OK ]

root@bt:~# netstat -natp


Active Internet connections (servers and established)
Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name
tcp 0 0 127.0.0.1:7337 0.0.0.0:* LISTEN 1058/postgres
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 12161/apache2
tcp 0 0 0.0.0.0:9876 0.0.0.0:* LISTEN 12161/apache2
tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 12144/sshd
tcp6 0 0 ::1:7337 :::* LISTEN 1058/postgres
tcp6 0 0 :::22 :::* LISTEN 12144/sshd
root@bt:~#
3. Navegando No Backtrack

4. Atualizando o Backtrack

root@bt:~# apt-get update


Get:9 http://all.repository.backtrack-linux.org revolution/testing Packages [75.5kB]
58% [7 Packages 6,236kB/10.7MB 58%]
352kB/s 12s^C
root@bt:~# apt-get upgrade

You might also like