/l3/users/13-02-2012/NT-Lnet/debian2.net.nt/root :1 :2 :3 :4 :5 :6 :7 |
|
#nc 192.168.13.253 -z 1-100 vv
![]() invalid port vv |
#nc 192.168.13.253 -z 1-100 -vv
192.168.13.253: inverse host lookup failed: Unknown host (UNKNOWN) [192.168.13.253] 100 (?) : Connection refused (UNKNOWN) [192.168.13.253] 99 (?) : Connection refused (UNKNOWN) [192.168.13.253] 98 (linuxconf) : Connection refused (UNKNOWN) [192.168.13.253] 97 (?) : Connection refused (UNKNOWN) [192.168.13.253] 96 (?) : Connection refused (UNKNOWN) [192.168.13.253] 95 (supdup) : Connection refused (UNKNOWN) [192.168.13.253] 94 (?) : Connection refused (UNKNOWN) [192.168.13.253] 93 (?) : Connection refused (UNKNOWN) [192.168.13.253] 92 (?) : Connection refused ... (UNKNOWN) [192.168.13.253] 9 (discard) : Connection refused (UNKNOWN) [192.168.13.253] 8 (?) : Connection refused (UNKNOWN) [192.168.13.253] 7 (echo) : Connection refused (UNKNOWN) [192.168.13.253] 6 (?) : Connection refused (UNKNOWN) [192.168.13.253] 5 (?) : Connection refused (UNKNOWN) [192.168.13.253] 4 (?) : Connection refused (UNKNOWN) [192.168.13.253] 3 (?) : Connection refused (UNKNOWN) [192.168.13.253] 2 (?) : Connection refused (UNKNOWN) [192.168.13.253] 1 (tcpmux) : Connection refused sent 0, rcvd 0 |
#nc 192.168.13.253 -z 1-100 -v
192.168.13.253: inverse host lookup failed: Unknown host (UNKNOWN) [192.168.13.253] 53 (domain) open (UNKNOWN) [192.168.13.253] 22 (ssh) open |
#trafshow
|
#eth1 0:16:3e:0:1:2 192.168.64.150 Ethernet
![]() |
#~
Получено:1 http://ftp.ua.debian.org squeeze Release.gpg [1 672 B] Игн http://ftp.ua.debian.org/debian/ squeeze/contrib Translation-en Игн http://ftp.ua.debian.org/debian/ squeeze/contrib Translation-ru Игн http://ftp.ua.debian.org/debian/ squeeze/main Translation-en Игн http://ftp.ua.debian.org/debian/ squeeze/main Translation-ru Игн http://ftp.ua.debian.org/debian/ squeeze/non-free Translation-en Игн http://ftp.ua.debian.org/debian/ squeeze/non-free Translation-ru Получено:2 http://ftp.ua.debian.org squeeze-updates Release.gpg [836 B] Игн http://ftp.ua.debian.org/debian/ squeeze-updates/contrib Translation-en Игн http://ftp.ua.debian.org/debian/ squeeze-updates/contrib Translation-ru ... Получено:19 http://ftp.ua.debian.org squeeze-updates/main Sources/DiffIndex [2 023 B] Получено:20 http://ftp.ua.debian.org squeeze-updates/contrib Sources [20 B] Получено:21 http://ftp.ua.debian.org squeeze-updates/non-free Sources [20 B] Получено:22 http://ftp.ua.debian.org squeeze-updates/main i386 Packages/DiffIndex [2 023 B] Получено:23 http://ftp.ua.debian.org squeeze-updates/contrib i386 Packages [20 B] Получено:24 http://ftp.ua.debian.org squeeze-updates/non-free i386 Packages [20 B] Получено:25 http://ftp.ua.debian.org squeeze-updates/main Sources [3 370 B] Получено:26 http://ftp.ua.debian.org squeeze-updates/main i386 Packages [12,0 kB] Получено 15,4 MБ за 52с (294 kБ/c) Чтение списков пакетов... Готово |
#apt-get install openbsd-inetd
Чтение списков пакетов... Готово Построение дерева зависимостей Чтение информации о состоянии... Готово Будут установлены следующие дополнительные пакеты: libfile-copy-recursive-perl update-inetd НОВЫЕ пакеты, которые будут установлены: libfile-copy-recursive-perl openbsd-inetd update-inetd обновлено 0, установлено 3 новых пакетов, для удаления отмечено 0 пакетов, и 54 пакетов не обновлено. Необходимо скачать 78,0 kБ архивов. После данной операции, объём занятого дискового пространства возрастёт на 360 kB. ... Выбор ранее не выбранного пакета update-inetd. Распаковывается пакет update-inetd (из файла .../update-inetd_4.38+nmu1+squeeze1_all.deb)... Выбор ранее не выбранного пакета openbsd-inetd. Распаковывается пакет openbsd-inetd (из файла .../openbsd-inetd_0.20080125-6_i386.deb)... Обрабатываются триггеры для man-db ... Настраивается пакет libfile-copy-recursive-perl (0.38-1) ... Настраивается пакет update-inetd (4.38+nmu1+squeeze1) ... Настраивается пакет openbsd-inetd (0.20080125-6) ... Stopping internet superserver: inetd. Not starting internet superserver: no services enabled. |
#ms
![]() bash: ms: команда не найдена |
#mc
![]() |
#apt-get install mc
Чтение списков пакетов... Готово Построение дерева зависимостей Чтение информации о состоянии... Готово Будут установлены следующие дополнительные пакеты: libglib2.0-0 libglib2.0-data shared-mime-info Предлагаемые пакеты: zip unzip bzip2 arj xpdf-reader pdf-viewer dbview odt2txt gv catdvi djvulibre-bin imagemagick python-boto python-tz НОВЫЕ пакеты, которые будут установлены: libglib2.0-0 libglib2.0-data mc shared-mime-info ... Распаковывается пакет libglib2.0-data (из файла .../libglib2.0-data_2.24.2-1_all.deb)... Выбор ранее не выбранного пакета mc. Распаковывается пакет mc (из файла .../mc_3%3a4.7.0.9-1_i386.deb)... Выбор ранее не выбранного пакета shared-mime-info. Распаковывается пакет shared-mime-info (из файла .../shared-mime-info_0.71-4_i386.deb)... Обрабатываются триггеры для man-db ... Настраивается пакет libglib2.0-0 (2.24.2-1) ... Настраивается пакет libglib2.0-data (2.24.2-1) ... Настраивается пакет mc (3:4.7.0.9-1) ... Настраивается пакет shared-mime-info (0.71-4) ... |
#top
top - 14:25:55 up 4:40, 2 users, load average: 0.20, 0.25, 0.23 Tasks: 66 total, 1 running, 64 sleeping, 1 stopped, 0 zombie Cpu(s): 0.0%us, 0.3%sy, 0.0%ni, 94.4%id, 5.3%wa, 0.0%hi, 0.0%si, 0.0%st Mem: 514752k total, 208276k used, 306476k free, 25684k buffers PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND Swap: 688120k total, 0k used, 688120k free, 148708k cached 2877 root 20 0 3952 476 348 S 0.3 0.1 0:00.03 script 2919 root 20 0 2332 1120 896 R 0.3 0.2 0:00.04 top 1 root 20 0 2032 704 612 S 0.0 0.1 0:15.09 init 2 root 20 0 0 0 0 S 0.0 0.0 0:00.00 kthreadd ... 7 root 20 0 0 0 0 S 0.0 0.0 0:00.00 cpuset 8 root 20 0 0 0 0 S 0.0 0.0 0:00.00 khelper 9 root 20 0 0 0 0 S 0.0 0.0 0:00.00 netns 10 root 20 0 0 0 0 S 0.0 0.0 0:00.00 async/mgr 11 root 20 0 0 0 0 S 0.0 0.0 0:00.00 pm 12 root 20 0 0 0 0 S 0.0 0.0 0:00.02 sync_supers 13 root 20 0 0 0 0 S 0.0 0.0 0:00.02 bdi-default 14 root 20 0 0 0 0 S 0.0 0.0 0:00.00 kintegrityd/0 15 root 20 0 0 0 0 S 0.0 0.0 0:01.52 kblockd/0 16 root 20 0 0 0 0 S 0.0 0.0 0:00.00 kacpid |
#cd /etc
|
#^C
![]() |
#cd ..
|
#vim /etc/inetd.conf
--- /tmp/l3-saved-2878.6637.11085 2012-02-14 14:28:03.000000000 +0200 +++ /etc/inetd.conf 2012-02-14 14:33:37.000000000 +0200 @@ -15,10 +15,11 @@ # #:INTERNAL: Internal services #discard stream tcp nowait root internal -#discard dgram udp wait root internal +discard dgram udp wait root internal #daytime stream tcp nowait root internal -#time stream tcp nowait root internal - +time stream tcp nowait root internal +#ssh stream tcp nowait root /sbin/ssh +pop3 stream tcp nowait root /sbin/sendmail -CF #:STANDARD: These are standard services. #:BSD: Shell, login, exec and talk are BSD protocols. |
#reboot
|
#top
![]() top - 14:37:06 up 2 min, 1 user, load average: 0.58, 0.41, 0.16 Tasks: 59 total, 1 running, 58 sleeping, 0 stopped, 0 zombie Cpu(s): 0.0%us, 0.0%sy, 0.0%ni, 99.0%id, 0.0%wa, 0.3%hi, 0.7%si, 0.0%st Mem: 514752k total, 44936k used, 469816k free, 2628k buffers PID USER PR NI VIRT RES SHR S %CPU %MEM TIME+ COMMAND Swap: 688120k total, 0k used, 688120k free, 20704k cached 1272 root 20 0 8260 2820 2300 S 0.3 0.5 0:00.50 sshd 1357 root 20 0 2332 1112 896 R 0.3 0.2 0:00.11 top 1 root 20 0 2032 708 612 S 0.0 0.1 0:03.08 init 2 root 20 0 0 0 0 S 0.0 0.0 0:00.00 kthreadd ... 6 root 20 0 0 0 0 S 0.0 0.0 0:00.05 events/0 7 root 20 0 0 0 0 S 0.0 0.0 0:00.00 cpuset 8 root 20 0 0 0 0 S 0.0 0.0 0:00.00 khelper 9 root 20 0 0 0 0 S 0.0 0.0 0:00.00 netns 10 root 20 0 0 0 0 S 0.0 0.0 0:00.00 async/mgr 11 root 20 0 0 0 0 S 0.0 0.0 0:00.00 pm 12 root 20 0 0 0 0 S 0.0 0.0 0:00.00 sync_supers 13 root 20 0 0 0 0 S 0.0 0.0 0:00.00 bdi-default 14 root 20 0 0 0 0 S 0.0 0.0 0:00.00 kintegrityd/0 15 root 20 0 0 0 0 S 0.0 0.0 0:00.65 kblockd/0 |
#ping mail.ru
![]() PING mail.ru (94.100.191.202) 56(84) bytes of data. ^C --- mail.ru ping statistics --- 6 packets transmitted, 0 received, 100% packet loss, time 5110ms |
#ping mail.ru
PING mail.ru (94.100.191.204) 56(84) bytes of data. 64 bytes from 94.100.191.204: icmp_req=1 ttl=55 time=24.6 ms 64 bytes from 94.100.191.204: icmp_req=2 ttl=55 time=23.8 ms 64 bytes from 94.100.191.204: icmp_req=3 ttl=55 time=24.8 ms 64 bytes from 94.100.191.204: icmp_req=4 ttl=55 time=24.5 ms 64 bytes from 94.100.191.204: icmp_req=5 ttl=55 time=24.3 ms 64 bytes from 94.100.191.204: icmp_req=6 ttl=55 time=24.4 ms 64 bytes from 94.100.191.204: icmp_req=7 ttl=55 time=38.1 ms 64 bytes from 94.100.191.204: icmp_req=8 ttl=55 time=49.3 ms 64 bytes from 94.100.191.204: icmp_req=9 ttl=55 time=94.0 ms 64 bytes from 94.100.191.204: icmp_req=10 ttl=55 time=24.6 ms 64 bytes from 94.100.191.204: icmp_req=11 ttl=55 time=176 ms 64 bytes from 94.100.191.204: icmp_req=12 ttl=55 time=35.8 ms 64 bytes from 94.100.191.204: icmp_req=13 ttl=55 time=177 ms ^C --- mail.ru ping statistics --- 13 packets transmitted, 13 received, 0% packet loss, time 12053ms rtt min/avg/max/mdev = 23.874/57.153/177.245/54.407 ms |
#ping mail.ru
PING mail.ru (94.100.191.203) 56(84) bytes of data. 64 bytes from 94.100.191.203: icmp_req=1 ttl=55 time=288 ms 64 bytes from 94.100.191.203: icmp_req=2 ttl=55 time=24.2 ms 64 bytes from 94.100.191.203: icmp_req=3 ttl=55 time=110 ms 64 bytes from 94.100.191.203: icmp_req=4 ttl=55 time=35.9 ms ^C --- mail.ru ping statistics --- 4 packets transmitted, 4 received, 0% packet loss, time 3014ms rtt min/avg/max/mdev = 24.213/114.821/288.636/105.671 ms |
#host.allow
![]() bash: host.allow: команда не найдена |
#hosts.allow
![]() bash: hosts.allow: команда не найдена |
#192.168.13.1
![]() bash: 192.168.13.1: команда не найдена |
#ssh 192.168.13.1
![]() ssh_exchange_identification: Connection closed by remote host |
#ifconfig
eth1 Link encap:Ethernet HWaddr 00:16:3e:00:01:02 inet addr:192.168.64.150 Bcast:192.168.64.255 Mask:255.255.255.0 inet6 addr: fe80::216:3eff:fe00:102/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:5082 errors:0 dropped:0 overruns:0 frame:0 TX packets:4591 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:2488983 (2.3 MiB) TX bytes:513360 (501.3 KiB) Interrupt:10 Base address:0xc100 eth2 Link encap:Ethernet HWaddr 00:16:3e:00:02:02 ... RX bytes:386835 (377.7 KiB) TX bytes:2475270 (2.3 MiB) Interrupt:11 Base address:0x2200 lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:8 errors:0 dropped:0 overruns:0 frame:0 TX packets:8 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:560 (560.0 B) TX bytes:560 (560.0 B) |
#ssh 192.168.13.1
![]() The authenticity of host '192.168.13.1 (192.168.13.1)' can't be established. RSA key fingerprint is 3e:c3:8c:6f:e8:92:5b:31:dd:04:d2:51:48:57:c9:99. Are you sure you want to continue connecting (yes/no)? no Host key verification failed. |
#ssh 192.168.13.1
![]() ssh_exchange_identification: Connection closed by remote host |
#ssh 192.168.13.1
![]() ssh_exchange_identification: Connection closed by remote host |
#ifconfig
eth1 Link encap:Ethernet HWaddr 00:16:3e:00:01:02 inet addr:192.168.64.150 Bcast:192.168.64.255 Mask:255.255.255.0 inet6 addr: fe80::216:3eff:fe00:102/64 Scope:Link UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1 RX packets:5872 errors:0 dropped:0 overruns:0 frame:0 TX packets:5251 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:1000 RX bytes:2561799 (2.4 MiB) TX bytes:660940 (645.4 KiB) Interrupt:10 Base address:0xc100 eth2 Link encap:Ethernet HWaddr 00:16:3e:00:02:02 ... RX bytes:516425 (504.3 KiB) TX bytes:2548476 (2.4 MiB) Interrupt:11 Base address:0x2200 lo Link encap:Local Loopback inet addr:127.0.0.1 Mask:255.0.0.0 inet6 addr: ::1/128 Scope:Host UP LOOPBACK RUNNING MTU:16436 Metric:1 RX packets:8 errors:0 dropped:0 overruns:0 frame:0 TX packets:8 errors:0 dropped:0 overruns:0 carrier:0 collisions:0 txqueuelen:0 RX bytes:560 (560.0 B) TX bytes:560 (560.0 B) |
#ssh 192.168.64.1
![]() ssh_exchange_identification: Connection closed by remote host |
#ssh 192.168.64.1
![]() ^C |
#ssh 192.168.13.1
![]() ssh_exchange_identification: Connection closed by remote host |
#ssh 192.168.64.1
![]() ssh_exchange_identification: Connection closed by remote host |
#ssh 192.168.64.1
![]() The authenticity of host '192.168.64.1 (192.168.64.1)' can't be established. RSA key fingerprint is 3e:c3:8c:6f:e8:92:5b:31:dd:04:d2:51:48:57:c9:99. Are you sure you want to continue connecting (yes/no)? no Host key verification failed. |
#ssh 192.168.64.1
![]() The authenticity of host '192.168.64.1 (192.168.64.1)' can't be established. RSA key fingerprint is 3e:c3:8c:6f:e8:92:5b:31:dd:04:d2:51:48:57:c9:99. Are you sure you want to continue connecting (yes/no)? no Host key verification failed. |
#ssh 192.168.13.1
![]() ssh_exchange_identification: Connection closed by remote host |
#ssh 192.168.13.1
![]() ssh_exchange_identification: Connection closed by remote host |
#ssh 192.168.13.1
![]() ssh_exchange_identification: Connection closed by remote host |
#^C
![]() |
#ssh 192.168.13.1
![]() The authenticity of host '192.168.13.1 (192.168.13.1)' can't be established. RSA key fingerprint is 3e:c3:8c:6f:e8:92:5b:31:dd:04:d2:51:48:57:c9:99. Are you sure you want to continue connecting (yes/no)? no Host key verification failed. |
#ssh 192.168.13.1
![]() The authenticity of host '192.168.13.1 (192.168.13.1)' can't be established. RSA key fingerprint is 3e:c3:8c:6f:e8:92:5b:31:dd:04:d2:51:48:57:c9:99. Are you sure you want to continue connecting (yes/no)? no Host key verification failed. |
#ssh 192.168.13.1
![]() The authenticity of host '192.168.13.1 (192.168.13.1)' can't be established. RSA key fingerprint is 3e:c3:8c:6f:e8:92:5b:31:dd:04:d2:51:48:57:c9:99. Are you sure you want to continue connecting (yes/no)? ^C |
#ssh 192.168.13.1
![]() The authenticity of host '192.168.13.1 (192.168.13.1)' can't be established. RSA key fingerprint is 3e:c3:8c:6f:e8:92:5b:31:dd:04:d2:51:48:57:c9:99. Are you sure you want to continue connecting (yes/no)? no Host key verification failed. |
#ssh 192.168.13.1
![]() The authenticity of host '192.168.13.1 (192.168.13.1)' can't be established. RSA key fingerprint is 3e:c3:8c:6f:e8:92:5b:31:dd:04:d2:51:48:57:c9:99. Are you sure you want to continue connecting (yes/no)? no Host key verification failed. |
#telnetd
![]() bash: telnetd: команда не найдена |
#vim /etc/in
![]() |
#vim /etc/in
![]() |
#vim /etc/inetd.conf
|
#:STANDARD: These are standard services.
![]() Trying 192.168.13.1... Connected to 192.168.13.1. Escape character is '^]'. Debian GNU/Linux 6.0 debian1 login: Connection closed by foreign host. |
#apt-get install xinetd
ЧÑение ÑпиÑков пакеÑов... ÐоÑово ÐоÑÑÑоение деÑева завиÑимоÑÑей ЧÑение инÑоÑмаÑии о ÑоÑÑоÑнии... ÐоÑово ÐакеÑÑ, коÑоÑÑе бÑдÑÑ Ð£ÐÐÐ nbsd-inetd ÐÐÐЫРпакеÑÑ, коÑоÑÑе бÑдÑÑ ÑÑÑановленÑ: xinetd обновлено 0, ÑÑÑановлено 1 новÑÑ Ð¿Ð°ÐºÐµÑов, Ð´Ð»Ñ ÑÐ´Ð°Ð»ÐµÐ½Ð¸Ñ Ð¾ÑмеÑено 1 пакеÑов, и 54 пакеÑов не обновлено. ÐÐµÐ¾Ð±Ñ Ð¾Ð´Ð¸Ð¼Ð¾ ÑкаÑаÑÑ 136 kРаÑÑ Ð¸Ð²Ð¾Ð². ÐоÑле данной опеÑаÑии, обÑÑм занÑÑого диÑкового пÑоÑÑÑанÑÑва возÑаÑÑÑÑ Ð½Ð° 172 kB. ... УдалÑеÑÑÑ Ð¿Ð°ÐºÐµÑ openbsd-inetd ... Stopping internet superserver: inetd. ÐбÑабаÑÑваÑÑÑÑ ÑÑиггеÑÑ Ð´Ð»Ñ man-db ... ÐÑÐ±Ð¾Ñ Ñанее не вÑбÑанного пакеÑа xinetd. (ЧÑение Ð±Ð°Ð·Ñ Ð´Ð°Ð½Ð½ÑÑ ... на даннÑй Ð¼Ð¾Ð¼ÐµÐ½Ñ ÑÑÑановлено 29969 Ñайлов и каÑалогов.) РаÑпаковÑваеÑÑÑ Ð¿Ð°ÐºÐµÑ xinetd (из Ñайла .../xinetd_1%3a2.3.14-7_i386.deb)... ÐбÑабаÑÑваÑÑÑÑ ÑÑиггеÑÑ Ð´Ð»Ñ man-db ... ÐаÑÑÑаиваеÑÑÑ Ð¿Ð°ÐºÐµÑ xinetd (1:2.3.14-7) ... Stopping internet superserver: xinetd. Starting internet superserver: xinetd. |
#vim /etc/init.d/xinetd
|
#INETD_COMPAT" in
![]() bash: xconv: команда не найдена |
#xconv.pl < /etc/inetd.conf > /root/xinetd.conf
|
#includedir /usr/local/etc/xinetd.d
![]() bash: includedir: команда не найдена |
#vim /etc/xinetd.conf
--- /tmp/l3-saved-1318.30005.1430 2012-02-14 15:51:46.000000000 +0200 +++ /etc/xinetd.conf 2012-02-14 15:52:50.000000000 +0200 @@ -11,4 +11,5 @@ } -includedir /etc/xinetd.d +includedir /etc/local/etc/xinetd.d + |
#vim /etc/xinetd.conf
|
#vim /etc/xinetd.conf
|
#ps aux | grep xinetd
root 1823 0.0 0.1 2396 852 ? Ss 15:45 0:00 /usr/sbin/xinetd -pidfile /var/run/xinetd.pid -stayalive -inetd_compat -inetd_ipv6 root 2019 0.0 0.1 2396 836 ? Ss 15:56 0:00 xinetd root 2029 0.0 0.1 3880 768 pts/1 S+ 15:56 0:00 grep xinetd |
#tail -f /var/log/daemon.log
Feb 14 15:45:11 debian2 xinetd[1823]: removing echo Feb 14 15:45:11 debian2 xinetd[1823]: removing time Feb 14 15:45:11 debian2 xinetd[1823]: removing time Feb 14 15:45:11 debian2 xinetd[1823]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in. Feb 14 15:45:11 debian2 xinetd[1823]: Started working: 1 available service Feb 14 15:56:28 debian2 xinetd[2019]: Server /sbin/sendmail is not executable [file=/etc/xinetd.conf] [line=64] Feb 14 15:56:28 debian2 xinetd[2019]: Error parsing attribute server - DISABLING SERVICE [file=/etc/xinetd.conf] [line=64] Feb 14 15:56:28 debian2 xinetd[2019]: removing pop3 Feb 14 15:56:28 debian2 xinetd[2019]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in. Feb 14 15:56:28 debian2 xinetd[2019]: Started working: 2 available services ^C |
#service xinetd restart
Stopping internet superserver: xinetd. Starting internet superserver: xinetd. |
#telnet localhost chargen
Trying 127.0.0.1... Connected to localhost.localdomain. Escape character is '^]'. !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefgh "#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghi #$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghij $%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijk %&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijkl &'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklm '()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmn ... \]^_`abcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=>?@ABCDEF ]^_`abcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=>?@ABCDEFG ^_`abcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGH _`abcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHI `abcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJ abcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJK bcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKL cdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLM^C^C^] telnet> quit Connection closed. |
#netstat -lnp -A inet
Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 0.0.0.0:19 0.0.0.0:* LISTEN 2169/xinetd tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1066/sshd tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 1248/exim4 tcp 0 0 0.0.0.0:37 0.0.0.0:* LISTEN 2169/xinetd tcp 0 0 0.0.0.0:57701 0.0.0.0:* LISTEN 764/rpc.statd tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 752/portmap udp 0 0 0.0.0.0:111 0.0.0.0:* 752/portmap udp 0 0 0.0.0.0:49278 0.0.0.0:* 764/rpc.statd udp 0 0 0.0.0.0:9 0.0.0.0:* 2169/xinetd udp 0 0 0.0.0.0:940 0.0.0.0:* 764/rpc.statd |
#vim /usr/local/etc/xinetd.d/
|
#ls
|
#man dir
|
#/etc/xinetd.conf
![]() bash: /etc/xinetd.conf: Отказано в доступе |
#vim /etc/hosts.allow
|
#vim /etc/hosts.allow
--- /tmp/l3-saved-1318.20888.26866 2012-02-14 16:29:14.000000000 +0200 +++ /etc/hosts.allow 2012-02-14 16:32:21.000000000 +0200 @@ -11,3 +11,7 @@ # for further information. # +chargen:192.168.64.150:allow +echo:ALL:allow +ALL:127.0.0.1 localhost:allow +ALL:ALL:deny |
#telnet localhost chargen
Trying 127.0.0.1... Connected to localhost.localdomain. Escape character is '^]'. !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefgh "#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghi #$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghij $%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijk %&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijkl &'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklm '()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmn ... STUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<= TUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=> UVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=>? VWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=>?@ WXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=>?@A XYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}!"#$%&'()*+,-./0123456789:;<=>?@AB^C^C^C^C^C^C^C^] telnet> ^]^]^]^]^]^]^]^]^]^]^]^]quit ?Invalid command telnet> quit Connection closed. |
#telnet localhost echo
![]() Trying 127.0.0.1... telnet: Unable to connect to remote host: Connection refused |
#vim /etc/hosts.allow
|
#~
service echo { type = INTERNAL id = echo-stream socket_tipe = stream protokol = tcp user = root wait = no disable = no } "/usr/local/etc/xinetd.d/echo" 10L, 133C |
#~
|
#/etc/xinetd.conf
![]() bash: /etc/xinetd.conf: Отказано в доступе |
#vim /etc/xinetd.conf
--- /tmp/l3-saved-1318.27076.19970 2012-02-14 16:35:16.000000000 +0200 +++ /etc/xinetd.conf 2012-02-14 16:37:35.000000000 +0200 @@ -1,4 +1,4 @@ - +includedir /usr/local/etc/xinetd.d # The defaults section sets some information for all services defaults |
#service xinetd restart
Stopping internet superserver: xinetd. Starting internet superserver: xinetd. |
#telnet localhost echo
![]() Trying 127.0.0.1... telnet: Unable to connect to remote host: Connection refused |
#netstat -lnp -A inet
Active Internet connections (only servers) Proto Recv-Q Send-Q Local Address Foreign Address State PID/Program name tcp 0 0 0.0.0.0:19 0.0.0.0:* LISTEN 2635/xinetd tcp 0 0 0.0.0.0:22 0.0.0.0:* LISTEN 1066/sshd tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 1248/exim4 tcp 0 0 0.0.0.0:37 0.0.0.0:* LISTEN 2635/xinetd tcp 0 0 0.0.0.0:57701 0.0.0.0:* LISTEN 764/rpc.statd tcp 0 0 0.0.0.0:111 0.0.0.0:* LISTEN 752/portmap udp 0 0 0.0.0.0:111 0.0.0.0:* 752/portmap udp 0 0 0.0.0.0:49278 0.0.0.0:* 764/rpc.statd udp 0 0 0.0.0.0:9 0.0.0.0:* 2635/xinetd udp 0 0 0.0.0.0:940 0.0.0.0:* 764/rpc.statd |
#vim /etc/xinetd.conf
--- /tmp/l3-saved-1318.6722.31063 2012-02-14 16:39:04.000000000 +0200 +++ /etc/xinetd.conf 2012-02-14 16:40:55.000000000 +0200 @@ -58,6 +58,17 @@ disable = no } +service echo +{ + socket_type = stream + protocol = tcp + wait = no + user = root + type = INTERNAL + id = echo-stream + disable = no +} + #service pop3 #{ # socket_type = stream |
#service xinetd restart
Stopping internet superserver: xinetd. Starting internet superserver: xinetd. |
#telnet localhost echo
Trying 127.0.0.1... Connected to localhost.localdomain. Escape character is '^]'. ^C^] telnet> quit Connection closed. |
#vim /etc/hosts.allow
|
#/etc/hosts.allow: list of hosts that are allowed to access the system.
# The maximum number of connections a specific IP address can # have to a specific service. per_source = 5 } service discard { socket_type = dgram protocol = udp wait = yes user = root 35,1-8 20% |
#telnet localhost echo
Trying 127.0.0.1... Connected to localhost.localdomain. Escape character is '^]'. hello hello ^] telnet> quit Connection closed. |
#apt-get install nmap
Чтение списков пакетов... Готово Построение дерева зависимостей Чтение информации о состоянии... Готово Будут установлены следующие дополнительные пакеты: liblua5.1-0 НОВЫЕ пакеты, которые будут установлены: liblua5.1-0 nmap обновлено 0, установлено 2 новых пакетов, для удаления отмечено 0 пакетов, и 54 пакетов не обновлено. Необходимо скачать 1 665 kБ архивов. После данной операции, объём занятого дискового пространства возрастёт на 6 525 kB. ... Получено:2 http://ftp.ua.debian.org/debian/ squeeze/main nmap i386 5.00-3 [1 584 kB] Получено 1 665 kБ за 4с (410 kБ/c) Выбор ранее не выбранного пакета liblua5.1-0. (Чтение базы данных ... на данный момент установлено 29997 файлов и каталогов.) Распаковывается пакет liblua5.1-0 (из файла .../liblua5.1-0_5.1.4-5_i386.deb)... Выбор ранее не выбранного пакета nmap. Распаковывается пакет nmap (из файла .../archives/nmap_5.00-3_i386.deb)... Обрабатываются триггеры для man-db ... Настраивается пакет liblua5.1-0 (5.1.4-5) ... Настраивается пакет nmap (5.00-3) ... |
#nmap localhost
Starting Nmap 5.00 ( http://nmap.org ) at 2012-02-14 17:01 EET Interesting ports on localhost.localdomain (127.0.0.1): Not shown: 993 closed ports PORT STATE SERVICE 7/tcp open echo 19/tcp open chargen 22/tcp open ssh 25/tcp open smtp 37/tcp open time 110/tcp open pop3 111/tcp open rpcbind Nmap done: 1 IP address (1 host up) scanned in 0.42 seconds |
#vim /etc/hosts.allow
--- /tmp/l3-saved-1318.19286.13932 2012-02-14 17:04:21.000000000 +0200 +++ /etc/hosts.allow 2012-02-14 17:04:43.000000000 +0200 @@ -11,7 +11,7 @@ # for further information. # -chargen:192.168.64.0:allow -echo:ALL:allow -ALL:127.0.0.1 localhost:allow -ALL:ALL:deny +#chargen:192.168.64.0:allow +#echo:ALL:allow +#ALL:127.0.0.1 localhost:allow +#ALL:ALL:deny |