Журнал лабораторных работ

Содержание

Журнал

Вторник (12/01/09)

/dev/ttyp4
13:08:29
#dpkg -L xinetd
/.
/etc
/etc/xinetd.d
/etc/xinetd.d/chargen
/etc/xinetd.d/daytime
/etc/xinetd.d/discard
/etc/xinetd.d/echo
/etc/xinetd.d/time
/etc/default
/etc/default/xinetd
...
/usr/share/doc/xinetd/README.update-inetd
/usr/share/doc/xinetd/xinetd.org-FAQ.html
/usr/share/doc/xinetd/README.Debian
/usr/share/doc/xinetd/copyright
/usr/share/doc/xinetd/examples
/usr/share/doc/xinetd/examples/sample.conf.gz
/usr/share/doc/xinetd/changelog.Debian.gz
/usr/share/doc/xinetd/NEWS.Debian.gz
/usr/share/doc/xinetd/changelog.gz
/usr/share/doc/xinetd/README.gz
13:08:36
#vim /etc/xinetd.conf
13:09:19
#Some defaults, and include /etc/xinetd.d/
chargen  daytime  discard  echo     time
13:09:19
#vim /etc/xinetd.d/
--- /tmp/l3-saved-1597.8105.25345	2009-12-01 14:10:28.000000000 +0200
+++ /etc/xinetd.d/bash	2009-12-01 14:13:19.000000000 +0200
@@ -1,40 +1,3 @@
-# This file generated by xconv.pl, included with the xinetd
-# package.  xconv.pl was written by Rob Braun (bbraun@synack.net)
-#
-# The file is merely a translation of your inetd.conf file into
-# the equivalent in xinetd.conf syntax.  xinetd has many 
-# features that may not be taken advantage of with this translation.
-# Please refer to the xinetd.conf man page for more information 
-# on how to properly configure xinetd.
-
-
-# The defaults section sets some information for all services
-defaults
-{
-	#The maximum number of requests a particular service may handle
-	# at once.
-	instances   = 25
-
-	# The type of logging.  This logs to a file that is specified.
-	# Another option is: SYSLOG syslog_facility [syslog_level]
-	log_type    = FILE /var/log/servicelog
-
-	# What to log when the connection succeeds.
-	# PID logs the pid of the server processing the request.
-	# HOST logs the remote host's ip address.
-	# USERID logs the remote user (using RFC 1413)
-	# EXIT logs the exit status of the server.
-	# DURATION logs the duration of the session.
-	log_on_success = HOST PID
-
-	# What to log when the connection fails.  Same options as above
-	log_on_failure = HOST
-
-	# The maximum number of connections a specific IP address can
-	# have to a specific service.  
-	per_source  = 5
-}
-
 service bash
 {
 	socket_type = stream
@@ -45,12 +8,4 @@
 	server_args = -i 
 }
 
-service calc
-{
-	socket_type = stream
-	protocol    = tcp
-	wait        = no
-	user        = root
-	server      = /usr/bin/bc
-}
 
13:09:36
#netstat -lnp | less
13:09:54
#xcon
xconsole  xconv.pl
13:09:54
#xcon
xconsole  xconv.pl
13:09:54
#xconv.pl < /etc/inetd.conf > /etc/xinetd.d/bash

13:10:25
#vim /etc/xinetd.d/bash
--- /tmp/l3-saved-1597.3708.2276	2009-12-01 14:14:37.000000000 +0200
+++ /etc/xinetd.d/bash	2009-12-01 14:14:48.000000000 +0200
@@ -5,7 +5,7 @@
 	wait        = no
 	user        = root
 	server      = bash
-	server_args = -i 
+	server_args = bash -i 
 }
 
 
13:13:22
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Dec  1 14:13:51 debian13 xinetd[5027]: Exiting...
Starting internet superserver: xinetd.
13:13:52
#Dec 1 14:13:52 debian13 xinetd[5315]: Reading included configuration file: /etc/xinetd.d/bash [file=/etc/xinetd.conf] [line=14]
Dec  1 14:13:52 debian13 xinetd[5315]: Server bash is not executable [file=/etc/xinetd.d/bash] [line=7]
Dec  1 14:13:52 debian13 xinetd[5315]: Error parsing attribute server - DISABLING SERVICE [file=/etc/xinetd.d/bash] [line=7]
Dec  1 14:13:52 debian13 xinetd[5315]: Reading included configuration file: /etc/xinetd.d/calc [file=/etc/xinetd.d/calc] [line=11]
Dec  1 14:13:52 debian13 xinetd[5315]: Reading included configuration file: /etc/xinetd.d/chargen [file=/etc/xinetd.d/chargen] [line=9]
Dec  1 14:13:52 debian13 xinetd[5315]: Reading included configuration file: /etc/xinetd.d/daytime [file=/etc/xinetd.d/daytime] [line=28]
Dec  1 14:13:52 debian13 xinetd[5315]: Reading included configuration file: /etc/xinetd.d/discard [file=/etc/xinetd.d/discard] [line=26]
Dec  1 14:13:52 debian13 xinetd[5315]: Reading included configuration file: /etc/xinetd.d/echo [file=/etc/xinetd.d/echo] [line=25]
Dec  1 14:13:52 debian13 xinetd[5315]: Reading included configuration file: /etc/xinetd.d/time [file=/etc/xinetd.d/time] [line=26]
Dec  1 14:13:52 debian13 xinetd[5315]: removing duplicate service bash [file=/etc/inetd.conf] [line=40]
Dec  1 14:13:52 debian13 xinetd[5315]: removing duplicate service calc [file=/etc/inetd.conf] [line=41]
...
Dec  1 14:13:52 debian13 xinetd[5315]: removing daytime
Dec  1 14:13:52 debian13 xinetd[5315]: removing daytime
Dec  1 14:13:52 debian13 xinetd[5315]: removing discard
Dec  1 14:13:52 debian13 xinetd[5315]: removing discard
Dec  1 14:13:52 debian13 xinetd[5315]: removing echo
Dec  1 14:13:52 debian13 xinetd[5315]: removing echo
Dec  1 14:13:52 debian13 xinetd[5315]: removing time
Dec  1 14:13:52 debian13 xinetd[5315]: removing time
Dec  1 14:13:52 debian13 xinetd[5315]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in.
Dec  1 14:13:52 debian13 xinetd[5315]: Started working: 1 available service
13:14:07
#less /var/log/daemon.log
13:14:48
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Dec  1 14:14:53 debian13 xinetd[5315]: Exiting...
Starting internet superserver: xinetd.
13:14:54
#Dec 1 14:14:54 debian13 xinetd[5410]: Reading included configuration file: /etc/xinetd.d/bash [file=/etc/xinetd.conf] [line=14]
Dec  1 14:14:54 debian13 xinetd[5410]: Server bash is not executable [file=/etc/xinetd.d/bash] [line=7]
Dec  1 14:14:54 debian13 xinetd[5410]: Error parsing attribute server - DISABLING SERVICE [file=/etc/xinetd.d/bash] [line=7]
Dec  1 14:14:54 debian13 xinetd[5410]: Reading included configuration file: /etc/xinetd.d/calc [file=/etc/xinetd.d/calc] [line=11]
Dec  1 14:14:54 debian13 xinetd[5410]: Reading included configuration file: /etc/xinetd.d/chargen [file=/etc/xinetd.d/chargen] [line=9]
Dec  1 14:14:54 debian13 xinetd[5410]: Reading included configuration file: /etc/xinetd.d/daytime [file=/etc/xinetd.d/daytime] [line=28]
Dec  1 14:14:54 debian13 xinetd[5410]: Reading included configuration file: /etc/xinetd.d/discard [file=/etc/xinetd.d/discard] [line=26]
Dec  1 14:14:54 debian13 xinetd[5410]: Reading included configuration file: /etc/xinetd.d/echo [file=/etc/xinetd.d/echo] [line=25]
Dec  1 14:14:54 debian13 xinetd[5410]: Reading included configuration file: /etc/xinetd.d/time [file=/etc/xinetd.d/time] [line=26]
Dec  1 14:14:54 debian13 xinetd[5410]: removing duplicate service bash [file=/etc/inetd.conf] [line=40]
Dec  1 14:14:54 debian13 xinetd[5410]: removing duplicate service calc [file=/etc/inetd.conf] [line=41]
...
Dec  1 14:14:54 debian13 xinetd[5410]: removing daytime
Dec  1 14:14:54 debian13 xinetd[5410]: removing daytime
Dec  1 14:14:54 debian13 xinetd[5410]: removing discard
Dec  1 14:14:54 debian13 xinetd[5410]: removing discard
Dec  1 14:14:54 debian13 xinetd[5410]: removing echo
Dec  1 14:14:54 debian13 xinetd[5410]: removing echo
Dec  1 14:14:54 debian13 xinetd[5410]: removing time
Dec  1 14:14:54 debian13 xinetd[5410]: removing time
Dec  1 14:14:54 debian13 xinetd[5410]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in.
Dec  1 14:14:54 debian13 xinetd[5410]: Started working: 1 available service
13:14:59
#vim /etc/xinetd.d/bash
--- /tmp/l3-saved-1597.461.7400	2009-12-01 14:15:01.000000000 +0200
+++ /etc/xinetd.d/bash	2009-12-01 14:15:18.000000000 +0200
@@ -4,7 +4,7 @@
 	protocol    = tcp
 	wait        = no
 	user        = root
-	server      = bash
+	server      = /bin/bash
 	server_args = bash -i 
 }
 
13:15:18
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Starting internet superserver: xinetd failed!
Dec  1 14:15:24 debian13 xinetd[5410]: Exiting...
13:15:24
#less /var/log/daemon.log
13:15:40
#Dec 1 14:15:40 debian13 xinetd[5516]: Reading included configuration file: /etc/xinetd.d/bash [file=/etc/xinetd.conf] [line=14]
Dec  1 14:15:40 debian13 xinetd[5516]: Reading included configuration file: /etc/xinetd.d/calc [file=/etc/xinetd.d/calc] [line=11]
Dec  1 14:15:40 debian13 xinetd[5516]: Reading included configuration file: /etc/xinetd.d/chargen [file=/etc/xinetd.d/chargen] [line=9]
Dec  1 14:15:40 debian13 xinetd[5516]: Reading included configuration file: /etc/xinetd.d/daytime [file=/etc/xinetd.d/daytime] [line=28]
Dec  1 14:15:40 debian13 xinetd[5516]: Reading included configuration file: /etc/xinetd.d/discard [file=/etc/xinetd.d/discard] [line=26]
Dec  1 14:15:40 debian13 xinetd[5516]: Reading included configuration file: /etc/xinetd.d/echo [file=/etc/xinetd.d/echo] [line=25]
Dec  1 14:15:40 debian13 xinetd[5516]: Reading included configuration file: /etc/xinetd.d/time [file=/etc/xinetd.d/time] [line=26]
Dec  1 14:15:40 debian13 xinetd[5516]: removing duplicate service bash [file=/etc/inetd.conf] [line=40]
Dec  1 14:15:40 debian13 xinetd[5516]: removing duplicate service calc [file=/etc/inetd.conf] [line=41]
Dec  1 14:15:40 debian13 xinetd[5516]: removing chargen
Dec  1 14:15:40 debian13 xinetd[5516]: removing chargen
Dec  1 14:15:40 debian13 xinetd[5516]: removing daytime
Dec  1 14:15:40 debian13 xinetd[5516]: removing daytime
Dec  1 14:15:40 debian13 xinetd[5516]: removing discard
Dec  1 14:15:40 debian13 xinetd[5516]: removing discard
Dec  1 14:15:40 debian13 xinetd[5516]: removing echo
Dec  1 14:15:40 debian13 xinetd[5516]: removing echo
Dec  1 14:15:40 debian13 xinetd[5516]: removing time
Dec  1 14:15:40 debian13 xinetd[5516]: removing time
Dec  1 14:15:40 debian13 xinetd[5516]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in.
Dec  1 14:15:40 debian13 xinetd[5516]: Started working: 2 available services
13:15:40
#less /var/log/daemon.log
13:15:59
#netstat -lnp | less
13:16:07
#nc 127.0.0.1 calc

13:16:21
#Dec 1 14:16:21 debian13 xinetd[5588]: libwrap refused connection to calc (libwrap=bc) from 127.0.0.1

13:16:23
#nc 127.0.0.1 bash

13:16:28
#Dec 1 14:16:28 debian13 xinetd[5604]: libwrap refused connection to bash (libwrap=bash) from 127.0.0.1

13:16:31
#vim /etc/hosts.allow
--- /tmp/l3-saved-1597.23491.12656	2009-12-01 14:16:37.000000000 +0200
+++ /etc/hosts.allow	2009-12-01 14:16:43.000000000 +0200
@@ -11,5 +11,5 @@
 # rpc.mountd (the NFS mount daemon). See portmap(8), rpc.mountd(8) and 
 # /usr/share/doc/portmap/portmapper.txt.gz for further information.
 #
-sshd: 0.0.0.0/0.0.0.0
-bc: 192.168.16.
+#sshd: 0.0.0.0/0.0.0.0
+#bc: 192.168.16.
13:16:43
#vim /etc/hosts.deny
--- /tmp/l3-saved-1597.10016.7723	2009-12-01 14:16:49.000000000 +0200
+++ /etc/hosts.deny	2009-12-01 14:16:55.000000000 +0200
@@ -17,4 +17,4 @@
 # validate looked up hostnames still leave understandable logs. In past
 # versions of Debian this has been the default.
 # ALL: PARANOID
-ALL: ALL
+#ALL: ALL
13:16:56
#nc 127.0.0.1 bash
/bin/bash: /bin/bash: cannot execute binary file
13:16:58
#vim /etc/xinetd.d/bash
13:17:30
# 3 socket_type = stream
...skipping...
Dec  1 14:15:40 debian13 xinetd[5516]: Reading included configuration file: /etc/xinetd.d/calc [file=/etc/xinetd
.d/calc] [line=11]bian1 init: Switching to runlevel: 0
Dec  1 14:15:40 debian13 xinetd[5516]: Reading included configuration file: /etc/xinetd.d/chargen [file=/etc/xin
etd.d/chargen] [line=9] init: Switching to runlevel: 0
Dec  1 14:15:40 debian13 xinetd[5516]: Reading included configuration file: /etc/xinetd.d/daytime [file=/etc/xinD1>\214 в
etd.d/daytime] [line=28]o space left on device
Dec  1 14:15:40 debian13 xinetd[5516]: Reading included configuration file: /etc/xinetd.d/discard [file=/etc/xin
etd.d/discard] [line=26]init: Switching to runlevel: 0
Dec  1 14:15:40 debian13 xinetd[5516]: Reading included configuration file: /etc/xinetd.d/echo [file=/etc/xinetd
...
Dec  1 14:15:40 debian13 xinetd[5516]: removing discard2.debian.pool.ntp.org
Dec  1 14:15:40 debian13 xinetd[5516]: removing echost 0.debian.pool.ntp.org
Dec  1 14:15:40 debian13 xinetd[5516]: removing echost 1.debian.pool.ntp.org
Dec  1 14:15:40 debian13 xinetd[5516]: removing timest 2.debian.pool.ntp.org
Dec  1 14:15:40 debian13 xinetd[5516]: removing timest 3.debian.pool.ntp.org
Dec  1 14:15:40 debian13 xinetd[5516]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in.
Dec  1 14:15:40 debian13 xinetd[5516]: Started working: 2 available services
Dec  1 14:16:21 debian13 xinetd[5588]: libwrap refused connection to calc (libwrap=bc) from 127.0.0.1
Dec  1 14:16:28 debian13 xinetd[5604]: libwrap refused connection to bash (libwrap=bash) from 127.0.0.1
Dec  1 14:16:39 debian13 xinetd[5647]: libwrap refused connection to bash (libwrap=bash) from 192.168.16.7
13:17:43
#vim /etc/xinetd.d/bash
--- /tmp/l3-saved-1597.4777.17833	2009-12-01 14:17:47.000000000 +0200
+++ /etc/xinetd.d/bash	2009-12-01 14:18:04.000000000 +0200
@@ -4,8 +4,7 @@
 	protocol    = tcp
 	wait        = no
 	user        = root
-	server      = /bin/bash
-	server_args = bash -i 
+	server      = /bin/bash -i
 }
 
 
13:18:04
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Dec  1 14:18:12 debian13 xinetd[5516]: Exiting...
Starting internet superserver: xinetd.
Dec  1 14:18:13 debian13 xinetd[5790]: Reading included configuration file: /etc/xinetd.d/bash [file=/etc/xinetd.conf] [line=14]
Dec  1 14:18:13 debian13 xinetd[5790]: attribute server expects 1 values and 2 values were specified [file=/etc/xinetd.d/bash] [line=7]
Dec  1 14:18:13 debian13 xinetd[5790]: Reading included configuration file: /etc/xinetd.d/calc [file=/etc/xinetd.d/calc] [line=10]
Dec  1 14:18:13 debian13 xinetd[5790]: Reading included configuration file: /etc/xinetd.d/chargen [file=/etc/xinetd.d/chargen] [line=9]
Dec  1 14:18:13 debian13 xinetd[5790]: Reading included configuration file: /etc/xinetd.d/daytime [file=/etc/xinetd.d/daytime] [line=28]
Dec  1 14:18:13 debian13 xinetd[5790]: Reading included configuration file: /etc/xinetd.d/discard [file=/etc/xinetd.d/discard] [line=26]
Dec  1 14:18:13 debian13 xinetd[5790]: Reading included configuration file: /etc/xinetd.d/echo [file=/etc/xinetd.d/echo] [line=25]
...
Dec  1 14:18:13 debian13 xinetd[5790]: removing daytime
Dec  1 14:18:13 debian13 xinetd[5790]: removing discard
Dec  1 14:18:13 debian13 xinetd[5790]: removing discard
Dec  1 14:18:13 debian13 xinetd[5790]: removing echo
Dec  1 14:18:13 debian13 xinetd[5790]: removing echo
Dec  1 14:18:13 debian13 xinetd[5790]: removing time
Dec  1 14:18:13 debian13 xinetd[5790]: removing time
Dec  1 14:18:13 debian13 xinetd[5790]: Must specify a server in bash
Dec  1 14:18:13 debian13 xinetd[5790]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in.
Dec  1 14:18:13 debian13 xinetd[5790]: Started working: 1 available service
13:18:13
#netstat -lnp | less
13:18:46
#vim /etc/xinetd.d/bash
--- /tmp/l3-saved-1597.32348.30606	2009-12-01 14:18:47.000000000 +0200
+++ /etc/xinetd.d/bash	2009-12-01 14:19:11.000000000 +0200
@@ -4,8 +4,8 @@
 	protocol    = tcp
 	wait        = no
 	user        = root
-	server      = /bin/bash -i
-	server_agrs = bash -i
+	server      = /bin/bash
+	server_args = bash -i
 }
 
 
13:19:11
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Dec  1 14:19:17 debian13 xinetd[5790]: Exiting...
Starting internet superserver: xinetd.
13:19:18
#Dec 1 14:19:18 debian13 xinetd[5871]: Reading included configuration file: /etc/xinetd.d/bash [file=/etc/xinetd.conf] [line=14]
Dec  1 14:19:18 debian13 xinetd[5871]: Reading included configuration file: /etc/xinetd.d/calc [file=/etc/xinetd.d/calc] [line=11]
Dec  1 14:19:18 debian13 xinetd[5871]: Reading included configuration file: /etc/xinetd.d/chargen [file=/etc/xinetd.d/chargen] [line=9]
Dec  1 14:19:18 debian13 xinetd[5871]: Reading included configuration file: /etc/xinetd.d/daytime [file=/etc/xinetd.d/daytime] [line=28]
Dec  1 14:19:18 debian13 xinetd[5871]: Reading included configuration file: /etc/xinetd.d/discard [file=/etc/xinetd.d/discard] [line=26]
Dec  1 14:19:18 debian13 xinetd[5871]: Reading included configuration file: /etc/xinetd.d/echo [file=/etc/xinetd.d/echo] [line=25]
Dec  1 14:19:18 debian13 xinetd[5871]: Reading included configuration file: /etc/xinetd.d/time [file=/etc/xinetd.d/time] [line=26]
Dec  1 14:19:18 debian13 xinetd[5871]: removing duplicate service bash [file=/etc/inetd.conf] [line=40]
Dec  1 14:19:18 debian13 xinetd[5871]: removing duplicate service calc [file=/etc/inetd.conf] [line=41]
Dec  1 14:19:18 debian13 xinetd[5871]: removing chargen
Dec  1 14:19:18 debian13 xinetd[5871]: removing chargen
Dec  1 14:19:18 debian13 xinetd[5871]: removing daytime
Dec  1 14:19:18 debian13 xinetd[5871]: removing daytime
Dec  1 14:19:18 debian13 xinetd[5871]: removing discard
Dec  1 14:19:18 debian13 xinetd[5871]: removing discard
Dec  1 14:19:18 debian13 xinetd[5871]: removing echo
Dec  1 14:19:18 debian13 xinetd[5871]: removing echo
Dec  1 14:19:18 debian13 xinetd[5871]: removing time
Dec  1 14:19:18 debian13 xinetd[5871]: removing time
Dec  1 14:19:18 debian13 xinetd[5871]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in.
Dec  1 14:19:18 debian13 xinetd[5871]: Started working: 2 available services
13:19:22
#nc 127.0.0.1 bash
/bin/bash: /bin/bash: cannot execute binary file
13:19:27
#telnet 127.0.0.1 bash
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
/bin/bash: /bin/bash: cannot execute binary file
Connection closed by foreign host.
13:19:34
#ls -l /bin/bash
-rwxr-xr-x 1 root root 677184 2006-12-11 23:20 /bin/bash
13:19:42
#vim /etc/xinetd.d/bash
--- /tmp/l3-saved-1597.25521.18404	2009-12-01 14:19:56.000000000 +0200
+++ /etc/xinetd.d/bash	2009-12-01 14:20:16.000000000 +0200
@@ -1,6 +1,7 @@
 service bash
 {
 	socket_type = stream
+	disable = no
 	protocol    = tcp
 	wait        = no
 	user        = root
13:20:16
#mqan xinet.conf
bash: mqan: command not found
13:20:24
#mqan xinetd.conf
bash: mqan: command not found
13:20:27
#man xinetd.conf
13:21:45
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Dec  1 14:21:53 debian13 xinetd[5871]: Exiting...
Starting internet superserver: xinetd.
13:21:54
#Dec 1 14:21:54 debian13 xinetd[6018]: Reading included configuration file: /etc/xinetd.d/bash [file=/etc/xinetd.conf] [line=14]
Dec  1 14:21:54 debian13 xinetd[6018]: Reading included configuration file: /etc/xinetd.d/calc [file=/etc/xinetd.d/calc] [line=12]
Dec  1 14:21:54 debian13 xinetd[6018]: Reading included configuration file: /etc/xinetd.d/chargen [file=/etc/xinetd.d/chargen] [line=9]
Dec  1 14:21:54 debian13 xinetd[6018]: Reading included configuration file: /etc/xinetd.d/daytime [file=/etc/xinetd.d/daytime] [line=28]
Dec  1 14:21:54 debian13 xinetd[6018]: Reading included configuration file: /etc/xinetd.d/discard [file=/etc/xinetd.d/discard] [line=26]
Dec  1 14:21:54 debian13 xinetd[6018]: Reading included configuration file: /etc/xinetd.d/echo [file=/etc/xinetd.d/echo] [line=25]
Dec  1 14:21:54 debian13 xinetd[6018]: Reading included configuration file: /etc/xinetd.d/time [file=/etc/xinetd.d/time] [line=26]
Dec  1 14:21:54 debian13 xinetd[6018]: removing duplicate service bash [file=/etc/inetd.conf] [line=40]
Dec  1 14:21:54 debian13 xinetd[6018]: removing duplicate service calc [file=/etc/inetd.conf] [line=41]
Dec  1 14:21:54 debian13 xinetd[6018]: removing chargen
Dec  1 14:21:54 debian13 xinetd[6018]: removing chargen
Dec  1 14:21:54 debian13 xinetd[6018]: removing daytime
Dec  1 14:21:54 debian13 xinetd[6018]: removing daytime
Dec  1 14:21:54 debian13 xinetd[6018]: removing discard
Dec  1 14:21:54 debian13 xinetd[6018]: removing discard
Dec  1 14:21:54 debian13 xinetd[6018]: removing echo
Dec  1 14:21:54 debian13 xinetd[6018]: removing echo
Dec  1 14:21:54 debian13 xinetd[6018]: removing time
Dec  1 14:21:54 debian13 xinetd[6018]: removing time
Dec  1 14:21:54 debian13 xinetd[6018]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in.
Dec  1 14:21:54 debian13 xinetd[6018]: Started working: 2 available services
13:21:54
#nc 127.0.0.1 bash

13:22:08
#ls -l
итого 17
drwxr-xr-x   2 root root 2480 2009-12-01 12:53 bin
drwxr-xr-x   2 root root   48 2006-10-28 17:06 boot
drwxr-xr-x  10 root root 2820 2009-12-01 12:03 dev
drwxr-xr-x  66 root root 3928 2009-12-01 14:16 etc
drwxr-xr-x 205 root root 4920 2008-03-14 11:04 home
drwxr-xr-x   2 root root   48 2007-12-23 16:30 initrd
drwxr-xr-x  12 root root 3920 2009-12-01 12:53 lib
drwx------   2 root root   48 2007-12-23 16:25 lost+found
drwxr-xr-x   2 root root   48 2007-12-23 16:30 media
dr-xr-xr-x   7 root root  920 2006-07-06 07:22 mnt
drwxr-xr-x   2 root root   48 2007-12-23 16:30 opt
dr-xr-xr-x 102 root root    0 2009-12-01 12:03 proc
drwxr-xr-x   7 root root  400 2009-12-01 14:21 root
drwxr-xr-x   2 root root 3040 2009-12-01 12:53 sbin
drwxr-xr-x   2 root root   48 2008-09-16 10:38 selinux
drwxr-xr-x   2 root root   48 2007-12-23 16:30 srv
drwxr-xr-x  12 root root    0 2009-12-01 12:03 sys
drwxrwxrwt   5 root root  200 2009-12-01 14:22 tmp
drwxr-xr-x  11 root root  264 2007-12-23 16:42 usr
drwxr-xr-x  13 root root  312 2008-03-14 16:53 var
не телетайп
13:22:08
#итого 17
drwxr-xr-x   2 root root 2480 2009-12-01 12:53 bin
                                                  drwxr-xr-x   2 root root   48 2006-10-28 17:06 boot
                                                                                                     drwxr-xr-x  10 root root 2820 2009-12-01 12:03 dev
                                                                                                                                                       drwxr-xr-x  66 root root 3928 2009-12-01 14:16 etc
                                                                                                                                                                                                         drwxr-xr-x 205 root root 4920 2008-03-14 11:04 home
                                                                                                                                                                                                                                                            drwxr-xr-x   2 root root   48 2007-12-23 16:30 initrd
                                                                                                                                                                                                                                                                                                                 drwxr-xr-x  12 root root 3920 2009-12-01 12:53 lib
                                                                                                                                                                                                                                                                                                                                                                   drwx------   2 root root   48 2007-12-23 16:l
                                                                                                                                                                                                                                                                                                                                                                                                               m
                                                                                                                                                                                                                                                                                                                                                                                                               m
                                                                                                                                                                                                                                                                                                                                                                                                               o
                                                                                                                                                                                                                                                                                                                                                                                                               p
                                                                                                                                                                                                                                                                                                                                                                                                               r
                                                                                                                                                                                                                                                                                                                                                                                                               s
                                                                                                                                                                                                                                                                                                                                                                                                               s
                                                                                                                                                                                                                                                                                                                                                                                                               s
                                                                                                                                                                                                                                                                                                                                                                                                               s
                                                                                                                                                                                                                                                                                                                                                                                                               t
                                                                                                                                                                                                                                                                                                                                                                                                               u
                                                                                                                                                                                                                                                                                                                                                                                                               v
/dev/ttyp4
13:22:10
#exit
exit
13:22:13
#vim /etc/xinetd.d/bash
--- /tmp/l3-saved-1597.29786.18584	2009-12-01 14:22:20.000000000 +0200
+++ /etc/xinetd.d/bash	2009-12-01 14:22:48.000000000 +0200
@@ -7,6 +7,7 @@
 	user        = root
 	server      = /bin/bash
 	server_args = -i
+	access_times = 14:00 - 15:00
 }
 
 
13:22:48
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Dec  1 14:22:51 debian13 xinetd[6018]: Exiting...
Starting internet superserver: xinetd.
Dec  1 14:22:52 debian13 xinetd[6151]: Reading included configuration file: /etc/xinetd.d/bash [file=/etc/xinetd.conf] [line=14]
Dec  1 14:22:52 debian13 xinetd[6151]: incorrect time interval [file=/etc/xinetd.d/bash] [line=10]
Dec  1 14:22:52 debian13 xinetd[6151]: Error parsing attribute access_times - DISABLING SERVICE [file=/etc/xinetd.d/bash] [line=10]
Dec  1 14:22:52 debian13 xinetd[6151]: Reading included configuration file: /etc/xinetd.d/calc [file=/etc/xinetd.d/calc] [line=13]
Dec  1 14:22:52 debian13 xinetd[6151]: Reading included configuration file: /etc/xinetd.d/chargen [file=/etc/xinetd.d/chargen] [line=9]
Dec  1 14:22:52 debian13 xinetd[6151]: Reading included configuration file: /etc/xinetd.d/daytime [file=/etc/xinetd.d/daytime] [line=28]
Dec  1 14:22:52 debian13 xinetd[6151]: Reading included configuration file: /etc/xinetd.d/discard [file=/etc/xinetd.d/discard] [line=26]
...
Dec  1 14:22:52 debian13 xinetd[6151]: removing daytime
Dec  1 14:22:52 debian13 xinetd[6151]: removing daytime
Dec  1 14:22:52 debian13 xinetd[6151]: removing discard
Dec  1 14:22:52 debian13 xinetd[6151]: removing discard
Dec  1 14:22:52 debian13 xinetd[6151]: removing echo
Dec  1 14:22:52 debian13 xinetd[6151]: removing echo
Dec  1 14:22:52 debian13 xinetd[6151]: removing time
Dec  1 14:22:52 debian13 xinetd[6151]: removing time
Dec  1 14:22:52 debian13 xinetd[6151]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in.
Dec  1 14:22:52 debian13 xinetd[6151]: Started working: 1 available service
13:22:52
#vim /etc/xinetd.d/bash
--- /tmp/l3-saved-1597.12732.26156	2009-12-01 14:22:56.000000000 +0200
+++ /etc/xinetd.d/bash	2009-12-01 14:23:07.000000000 +0200
@@ -7,7 +7,7 @@
 	user        = root
 	server      = /bin/bash
 	server_args = -i
-	access_times = 14:00 - 15:00
+	access_times = 14:00-15:00
 }
 
 
13:23:07
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Starting internet superserver: xinetd failed!
13:23:11
#Dec 1 14:23:11 debian13 xinetd[6151]: Exiting...

13:23:14
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Starting internet superserver: xinetd.
13:23:19
#Dec 1 14:23:20 debian13 xinetd[6256]: Reading included configuration file: /etc/xinetd.d/bash [file=/etc/xinetd.conf] [line=14]
Dec  1 14:23:20 debian13 xinetd[6256]: Reading included configuration file: /etc/xinetd.d/calc [file=/etc/xinetd.d/calc] [line=13]
Dec  1 14:23:20 debian13 xinetd[6256]: Reading included configuration file: /etc/xinetd.d/chargen [file=/etc/xinetd.d/chargen] [line=9]
Dec  1 14:23:20 debian13 xinetd[6256]: Reading included configuration file: /etc/xinetd.d/daytime [file=/etc/xinetd.d/daytime] [line=28]
Dec  1 14:23:20 debian13 xinetd[6256]: Reading included configuration file: /etc/xinetd.d/discard [file=/etc/xinetd.d/discard] [line=26]
Dec  1 14:23:20 debian13 xinetd[6256]: Reading included configuration file: /etc/xinetd.d/echo [file=/etc/xinetd.d/echo] [line=25]
Dec  1 14:23:20 debian13 xinetd[6256]: Reading included configuration file: /etc/xinetd.d/time [file=/etc/xinetd.d/time] [line=26]
Dec  1 14:23:20 debian13 xinetd[6256]: removing duplicate service bash [file=/etc/inetd.conf] [line=40]
Dec  1 14:23:20 debian13 xinetd[6256]: removing duplicate service calc [file=/etc/inetd.conf] [line=41]
Dec  1 14:23:20 debian13 xinetd[6256]: removing chargen
Dec  1 14:23:20 debian13 xinetd[6256]: removing chargen
Dec  1 14:23:20 debian13 xinetd[6256]: removing daytime
Dec  1 14:23:20 debian13 xinetd[6256]: removing daytime
Dec  1 14:23:20 debian13 xinetd[6256]: removing discard
Dec  1 14:23:20 debian13 xinetd[6256]: removing discard
Dec  1 14:23:20 debian13 xinetd[6256]: removing echo
Dec  1 14:23:20 debian13 xinetd[6256]: removing echo
Dec  1 14:23:20 debian13 xinetd[6256]: removing time
Dec  1 14:23:20 debian13 xinetd[6256]: removing time
Dec  1 14:23:20 debian13 xinetd[6256]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in.
Dec  1 14:23:20 debian13 xinetd[6256]: Started working: 2 available services
13:23:19
#nc 127.0.0.1 bash

13:23:34
#exit
exit
13:23:36
#vim /etc/xinetd.d/bash
--- /tmp/l3-saved-1597.9824.17464	2009-12-01 14:23:39.000000000 +0200
+++ /etc/xinetd.d/bash	2009-12-01 14:23:47.000000000 +0200
@@ -7,7 +7,7 @@
 	user        = root
 	server      = /bin/bash
 	server_args = -i
-	access_times = 14:00-15:00
+	access_times = 13:00-14:00
 }
 
 
13:23:47
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Dec  1 14:23:51 debian13 xinetd[6256]: Exiting...
Starting internet superserver: xinetd.
13:23:52
#Dec 1 14:23:52 debian13 xinetd[6379]: Reading included configuration file: /etc/xinetd.d/bash [file=/etc/xinetd.conf] [line=14]
Dec  1 14:23:52 debian13 xinetd[6379]: Reading included configuration file: /etc/xinetd.d/calc [file=/etc/xinetd.d/calc] [line=13]
Dec  1 14:23:52 debian13 xinetd[6379]: Reading included configuration file: /etc/xinetd.d/chargen [file=/etc/xinetd.d/chargen] [line=9]
Dec  1 14:23:52 debian13 xinetd[6379]: Reading included configuration file: /etc/xinetd.d/daytime [file=/etc/xinetd.d/daytime] [line=28]
Dec  1 14:23:52 debian13 xinetd[6379]: Reading included configuration file: /etc/xinetd.d/discard [file=/etc/xinetd.d/discard] [line=26]
Dec  1 14:23:52 debian13 xinetd[6379]: Reading included configuration file: /etc/xinetd.d/echo [file=/etc/xinetd.d/echo] [line=25]
Dec  1 14:23:52 debian13 xinetd[6379]: Reading included configuration file: /etc/xinetd.d/time [file=/etc/xinetd.d/time] [line=26]
Dec  1 14:23:52 debian13 xinetd[6379]: removing duplicate service bash [file=/etc/inetd.conf] [line=40]
Dec  1 14:23:52 debian13 xinetd[6379]: removing duplicate service calc [file=/etc/inetd.conf] [line=41]
Dec  1 14:23:52 debian13 xinetd[6379]: removing chargen
Dec  1 14:23:52 debian13 xinetd[6379]: removing chargen
Dec  1 14:23:52 debian13 xinetd[6379]: removing daytime
Dec  1 14:23:52 debian13 xinetd[6379]: removing daytime
Dec  1 14:23:52 debian13 xinetd[6379]: removing discard
Dec  1 14:23:52 debian13 xinetd[6379]: removing discard
Dec  1 14:23:52 debian13 xinetd[6379]: removing echo
Dec  1 14:23:52 debian13 xinetd[6379]: removing echo
Dec  1 14:23:52 debian13 xinetd[6379]: removing time
Dec  1 14:23:52 debian13 xinetd[6379]: removing time
Dec  1 14:23:52 debian13 xinetd[6379]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in.
Dec  1 14:23:52 debian13 xinetd[6379]: Started working: 2 available services
13:23:54
#nc 127.0.0.1 bash

13:23:56
#nc 127.0.0.1 bash

13:23:57
#telnet 127.0.0.1 bash
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
Connection closed by foreign host.
13:24:04
#man xinetd.conf
13:25:48
#man xinetd.conf
13:26:36
#echo "Hello boy" > /tmp/welcome

13:26:54
#echo "Витаемо! ви увiйшли!" > tmp/success
>
13:27:30
#echo "Hello boy" > /tmp/welcome

13:27:33
#echo "Витаемо, ви увiйшли" > /tmp/success

13:27:42
#echo goodbye > /tmp/fail

13:27:57
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Starting internet superserver: xinetd failed!
13:28:05
#Dec 1 14:28:05 debian13 xinetd[6379]: Exiting...

13:28:07
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Starting internet superserver: xinetd.
Dec  1 14:28:11 debian13 xinetd[6625]: Reading included configuration file: /etc/xinetd.d/bash [file=/etc/xinetd.conf] [line=14]
Dec  1 14:28:11 debian13 xinetd[6625]: Reading included configuration file: /etc/xinetd.d/calc [file=/etc/xinetd.d/calc] [line=18]
Dec  1 14:28:11 debian13 xinetd[6625]: Reading included configuration file: /etc/xinetd.d/chargen [file=/etc/xinetd.d/chargen] [line=9]
Dec  1 14:28:11 debian13 xinetd[6625]: Reading included configuration file: /etc/xinetd.d/daytime [file=/etc/xinetd.d/daytime] [line=28]
Dec  1 14:28:11 debian13 xinetd[6625]: Reading included configuration file: /etc/xinetd.d/discard [file=/etc/xinetd.d/discard] [line=26]
Dec  1 14:28:11 debian13 xinetd[6625]: Reading included configuration file: /etc/xinetd.d/echo [file=/etc/xinetd.d/echo] [line=25]
Dec  1 14:28:11 debian13 xinetd[6625]: Reading included configuration file: /etc/xinetd.d/time [file=/etc/xinetd.d/time] [line=26]
Dec  1 14:28:11 debian13 xinetd[6625]: removing duplicate service bash [file=/etc/inetd.conf] [line=40]
...
Dec  1 14:28:11 debian13 xinetd[6625]: removing daytime
Dec  1 14:28:11 debian13 xinetd[6625]: removing daytime
Dec  1 14:28:11 debian13 xinetd[6625]: removing discard
Dec  1 14:28:11 debian13 xinetd[6625]: removing discard
Dec  1 14:28:11 debian13 xinetd[6625]: removing echo
Dec  1 14:28:11 debian13 xinetd[6625]: removing echo
Dec  1 14:28:11 debian13 xinetd[6625]: removing time
Dec  1 14:28:11 debian13 xinetd[6625]: removing time
Dec  1 14:28:11 debian13 xinetd[6625]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in.
Dec  1 14:28:11 debian13 xinetd[6625]: Started working: 2 available services
13:28:17
#telnet 127.0.0.1 bash
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
Hello boy
goodbye
Connection closed by foreign host.
13:28:22
#vim /etc/xinetd.d/bash
--- /tmp/l3-saved-1597.4073.17252	2009-12-01 14:28:30.000000000 +0200
+++ /etc/xinetd.d/bash	2009-12-01 14:28:38.000000000 +0200
@@ -7,7 +7,7 @@
 	user        = root
 	server      = /bin/bash
 	server_args = -i
-	access_times = 13:00-14:00
+	access_times = 13:00-17:00
 bind = 127.0.0.1
 banner = /tmp/welcome
 banner_success = /tmp/success
13:28:38
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Starting internet superserver: xinetd failed!
13:28:43
#Dec 1 14:28:43 debian13 xinetd[6625]: Exiting...

13:28:44
#invoke-rc.d xinetd restart
Stopping internet superserver: xinetd.
Starting internet superserver: xinetd.
Dec  1 14:28:48 debian13 xinetd[6759]: Reading included configuration file: /etc/xinetd.d/bash [file=/etc/xinetd.conf] [line=14]
Dec  1 14:28:48 debian13 xinetd[6759]: Reading included configuration file: /etc/xinetd.d/calc [file=/etc/xinetd.d/calc] [line=18]
Dec  1 14:28:48 debian13 xinetd[6759]: Reading included configuration file: /etc/xinetd.d/chargen [file=/etc/xinetd.d/chargen] [line=9]
Dec  1 14:28:48 debian13 xinetd[6759]: Reading included configuration file: /etc/xinetd.d/daytime [file=/etc/xinetd.d/daytime] [line=28]
Dec  1 14:28:48 debian13 xinetd[6759]: Reading included configuration file: /etc/xinetd.d/discard [file=/etc/xinetd.d/discard] [line=26]
Dec  1 14:28:48 debian13 xinetd[6759]: Reading included configuration file: /etc/xinetd.d/echo [file=/etc/xinetd.d/echo] [line=25]
Dec  1 14:28:48 debian13 xinetd[6759]: Reading included configuration file: /etc/xinetd.d/time [file=/etc/xinetd.d/time] [line=26]
Dec  1 14:28:48 debian13 xinetd[6759]: removing duplicate service bash [file=/etc/inetd.conf] [line=40]
...
Dec  1 14:28:48 debian13 xinetd[6759]: removing daytime
Dec  1 14:28:48 debian13 xinetd[6759]: removing daytime
Dec  1 14:28:48 debian13 xinetd[6759]: removing discard
Dec  1 14:28:48 debian13 xinetd[6759]: removing discard
Dec  1 14:28:48 debian13 xinetd[6759]: removing echo
Dec  1 14:28:48 debian13 xinetd[6759]: removing echo
Dec  1 14:28:48 debian13 xinetd[6759]: removing time
Dec  1 14:28:48 debian13 xinetd[6759]: removing time
Dec  1 14:28:48 debian13 xinetd[6759]: xinetd Version 2.3.14 started with libwrap loadavg options compiled in.
Dec  1 14:28:48 debian13 xinetd[6759]: Started working: 2 available services
13:28:48
#telnet 127.0.0.1 bash
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
Hello boy
Витаемо, ви увiйшли
13:28:53
#ls
bin   dev  home    lib         media  opt   root  selinux  sys  usr
boot  etc  initrd  lost+found  mnt    proc  sbin  srv      tmp  var
не телетайп
13:28:53
#bin dev home lib media opt root selinux sys usr
boot  etc  initrd  lost+found  mnt    proc  sbin  srv      tmp  var
/dev/ttyp4
13:28:56
#exit
exit
Connection closed by foreign host.
13:28:59
#top
top - 14:30:02 up  2:26,  7 users,  load average: 1.96, 2.01, 1.53
Tasks:  87 total,   4 running,  83 sleeping,   0 stopped,   0 zombie
Cpu(s): 93.0%us,  7.0%sy,  0.0%ni,  0.0%id,  0.0%wa,  0.0%hi,  0.0%si,  0.0%st
Mem:    594068k total,   265540k used,   328528k free,    38584k buffers
  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
Swap:        0k total,        0k used,        0k free,   139812k cached
 1469 root      25   0 22804  17m 1484 R 50.3  3.0  78:52.81 l3-agent
 4433 user      25   0 16608  11m 1484 R 49.7  2.0  14:33.97 l3-agent
    1 root      15   0  1988  644  552 S  0.0  0.1   0:00.06 init
    1 root      15   0  1988  644  552 S  0.0  0.1   0:00.06 init
...
 1469 root      25   0 22804  17m 1484 R 50.3  3.0  80:30.22 l3-agent
 4433 user      25   0 16608  11m 1484 R 49.7  2.0  16:02.36 l3-agent
top - 14:33:11 up  2:29,  7 users,  load average: 1.97, 1.97, 1.60
Tasks:  87 total,   3 running,  84 sleeping,   0 stopped,   0 zombie
Cpu(s): 93.3%us,  6.7%sy,  0.0%ni,  0.0%id,  0.0%wa,  0.0%hi,  0.0%si,  0.0%st
Mem:    594068k total,   266160k used,   327908k free,    38584k buffers
  PID USER      PR  NI  VIRT  RES  SHR S %CPU %MEM    TIME+  COMMAND
Swap:        0k total,        0k used,        0k free,   140584k cached
 1469 root      25   0 22804  17m 1484 R 50.7  3.0  80:31.74 l3-agent
 4433 user      25   0 16608  11m 1484 R 49.7  2.0  16:03.85 l3-agent
13:33:14
#apt-get install popa3d
Выбор ранее не выбранного пакета popa3d.
(Чтение базы данных... на данный момент установлено 25049 файлов и каталогов.)
Распаковывается пакет popa3d (из файла .../popa3d_1.0.2-4_i386.deb)...
Выбор ранее не выбранного пакета liblockfile1.
Распаковывается пакет liblockfile1 (из файла .../liblockfile1_1.08-3_i386.deb)...
Выбор ранее не выбранного пакета exim4-config.
Распаковывается пакет exim4-config (из файла .../exim4-config_4.69-9_all.deb)...
Выбор ранее не выбранного пакета exim4-base.
Распаковывается пакет exim4-base (из файла .../exim4-base_4.69-9_i386.deb)...
Выбор ранее не выбранного пакета exim4-daemon-light.
...
Starting pop daemon: popa3d.
Настраивается пакет liblockfile1 (1.08-3) ...
Настраивается пакет exim4-config (4.69-9) ...
Adding system-user for exim (v4)
Настраивается пакет exim4-base (4.69-9) ...
Настраивается пакет exim4-daemon-light (4.69-9) ...
Starting MTA: exim4.
Настраивается пакет exim4 (4.69-9) ...
Настраивается пакет bsd-mailx (8.1.2-0.20071201cvs-3) ...
Настраивается пакет mailx (1:20071201-3) ...
13:35:53
#netstat -r
Kernel IP routing table
Destination     Gateway         Genmask         Flags   MSS Window  irtt Iface
192.168.16.0    *               255.255.255.0   U         0 0          0 eth0
default         debian.net.nt   0.0.0.0         UG        0 0          0 eth0
13:36:01
#route -n
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.16.0    0.0.0.0         255.255.255.0   U     0      0        0 eth0
0.0.0.0         192.168.16.254  0.0.0.0         UG    0      0        0 eth0
13:36:24
#netstat -lnp | less
13:36:36
#nc 127.0.0.1 110
Dec  1 14:36:42 debian13 popa3d[7924]: Session from 127.0.0.1
+OK
USER user
+OK
PASS password
+OK
Dec  1 14:36:50 debian13 popa3d[7924]: Authentication passed for user
Dec  1 14:36:50 debian13 popa3d[7924]: 0 messages (0 bytes) loaded
LIST
+OK
.
QUIT
+OK
13:37:00
#Dec 1 14:37:00 debian13 popa3d[7924]: 0 (0) deleted, 0 (0) left

13:37:13
#mkfifo /tmp/fifo

13:37:23
#ls -l /tmp/fifo
prw-r--r-- 1 root root 0 2009-12-01 14:37 /tmp/fifo
13:37:25
#nc 127.0.0.1 110 < /tmp/fifo | nc -l -p 1100 > /tmp/fifo
Dec  1 14:38:28 debian13 popa3d[7958]: Session from 127.0.0.1
USER user
13:38:59
#nohup 'nc 127.0.0.1 110 < /tmp/fifo | nc -l -p 1100 > /tmp/fifo'
nohup: вывод добавляется в `nohup.out'
nohup: невозможно выполнить команду `nc 127.0.0.1 110 < /tmp/fifo | nc -l -p 1100 > /tmp/fifo': Нет такого файла или каталога
13:39:18
#man nohup
13:39:54
#Dec 1 14:39:54 debian13 popa3d[8017]: Didn't attempt authentication

13:39:57
#nohup nc 127.0.0.1 110 < /tmp/fifo | nohup nc -l -p 1100 > /tmp/fifo
Dec  1 14:40:10 debian13 popa3d[8087]: Session from 127.0.0.1
13:40:12
#Dec 1 14:40:11 debian13 popa3d[8087]: Didn't attempt authentication

13:40:15
#nc 127.0.0.1 110 < /tmp/fifo | nc -l -p 1100 > /tmp/fifo
Dec  1 14:40:17 debian13 popa3d[8140]: Session from 127.0.0.1
Dec  1 14:40:50 debian13 popa3d[8140]: Authentication passed for user
Dec  1 14:40:50 debian13 popa3d[8140]: 0 messages (0 bytes) loaded
Dec  1 14:40:53 debian13 popa3d[8140]: 0 (0) deleted, 0 (0) left
Dec  1 14:40:55 debian13 popa3d[8175]: Session from 192.168.16.1
13:40:57
#nc 127.0.0.1 110 < /tmp/fifo | nc -l -p 1100 > /tmp/fifo
Dec  1 14:41:04 debian13 popa3d[8200]: Session from 127.0.0.1
Dec  1 14:41:09 debian13 popa3d[8175]: Authentication passed for user
Dec  1 14:41:09 debian13 popa3d[8175]: 0 messages (0 bytes) loaded
13:41:22
#Dec 1 14:41:32 debian13 popa3d[8175]: Premature disconnect

13:41:22
#dd if=/dev/hda | ssh 'dd of=/dev/hdb'

Статистика

Время первой команды журнала13:08:29 2009-12- 1
Время последней команды журнала13:41:22 2009-12- 1
Количество командных строк в журнале101
Процент команд с ненулевым кодом завершения, %15.84
Процент синтаксически неверно набранных команд, % 2.97
Суммарное время работы с терминалом *, час 0.55
Количество командных строк в единицу времени, команда/мин 3.07
Частота использования команд
Dec16|=============| 13.33%
invoke-rc.d14|===========| 11.67%
vim14|===========| 11.67%
nc13|==========| 10.83%
less7|=====| 5.83%
echo5|====| 4.17%
netstat5|====| 4.17%
fifo5|====| 4.17%
telnet4|===| 3.33%
man4|===| 3.33%
ls4|===| 3.33%
exit3|==| 2.50%
welcome2|=| 1.67%
nohup2|=| 1.67%
mqan2|=| 1.67%
success2|=| 1.67%
xcon2|=| 1.67%
dpkg1|| 0.83%
Some1|| 0.83%
top1|| 0.83%
route1|| 0.83%
fifo'1|| 0.83%
dd1|| 0.83%
31|| 0.83%
fail1|| 0.83%
xconv.pl1|| 0.83%
mkfifo1|| 0.83%
итого1|| 0.83%
apt-get1|| 0.83%
/etc/xinetd.d/bash1|| 0.83%
/etc/inetd.conf1|| 0.83%
ssh1|| 0.83%
bin1|| 0.83%
____
*) Интервалы неактивности длительностью 30 минут и более не учитываются

Справка

Для того чтобы использовать LiLaLo, не нужно знать ничего особенного: всё происходит само собой. Однако, чтобы ведение и последующее использование журналов было как можно более эффективным, желательно иметь в виду следующее:
  1. В журнал автоматически попадают все команды, данные в любом терминале системы.

  2. Для того чтобы убедиться, что журнал на текущем терминале ведётся, и команды записываются, дайте команду w. В поле WHAT, соответствующем текущему терминалу, должна быть указана программа script.

  3. Команды, при наборе которых были допущены синтаксические ошибки, выводятся перечёркнутым текстом:
    $ l s-l
    bash: l: command not found
    

  4. Если код завершения команды равен нулю, команда была выполнена без ошибок. Команды, код завершения которых отличен от нуля, выделяются цветом.
    $ test 5 -lt 4
    Обратите внимание на то, что код завершения команды может быть отличен от нуля не только в тех случаях, когда команда была выполнена с ошибкой. Многие команды используют код завершения, например, для того чтобы показать результаты проверки

  5. Команды, ход выполнения которых был прерван пользователем, выделяются цветом.
    $ find / -name abc
    find: /home/devi-orig/.gnome2: Keine Berechtigung
    find: /home/devi-orig/.gnome2_private: Keine Berechtigung
    find: /home/devi-orig/.nautilus/metafiles: Keine Berechtigung
    find: /home/devi-orig/.metacity: Keine Berechtigung
    find: /home/devi-orig/.inkscape: Keine Berechtigung
    ^C
    

  6. Команды, выполненные с привилегиями суперпользователя, выделяются слева красной чертой.
    # id
    uid=0(root) gid=0(root) Gruppen=0(root)
    

  7. Изменения, внесённые в текстовый файл с помощью редактора, запоминаются и показываются в журнале в формате ed. Строки, начинающиеся символом "<", удалены, а строки, начинающиеся символом ">" -- добавлены.
    $ vi ~/.bashrc
    2a3,5
    >    if [ -f /usr/local/etc/bash_completion ]; then
    >         . /usr/local/etc/bash_completion
    >        fi
    

  8. Для того чтобы изменить файл в соответствии с показанными в диффшоте изменениями, можно воспользоваться командой patch. Нужно скопировать изменения, запустить программу patch, указав в качестве её аргумента файл, к которому применяются изменения, и всавить скопированный текст:
    $ patch ~/.bashrc
    В данном случае изменения применяются к файлу ~/.bashrc

  9. Для того чтобы получить краткую справочную информацию о команде, нужно подвести к ней мышь. Во всплывающей подсказке появится краткое описание команды.

    Если справочная информация о команде есть, команда выделяется голубым фоном, например: vi. Если справочная информация отсутствует, команда выделяется розовым фоном, например: notepad.exe. Справочная информация может отсутствовать в том случае, если (1) команда введена неверно; (2) если распознавание команды LiLaLo выполнено неверно; (3) если информация о команде неизвестна LiLaLo. Последнее возможно для редких команд.

  10. Большие, в особенности многострочные, всплывающие подсказки лучше всего показываются браузерами KDE Konqueror, Apple Safari и Microsoft Internet Explorer. В браузерах Mozilla и Firefox они отображаются не полностью, а вместо перевода строки выводится специальный символ.

  11. Время ввода команды, показанное в журнале, соответствует времени начала ввода командной строки, которое равно тому моменту, когда на терминале появилось приглашение интерпретатора

  12. Имя терминала, на котором была введена команда, показано в специальном блоке. Этот блок показывается только в том случае, если терминал текущей команды отличается от терминала предыдущей.

  13. Вывод не интересующих вас в настоящий момент элементов журнала, таких как время, имя терминала и других, можно отключить. Для этого нужно воспользоваться формой управления журналом вверху страницы.

  14. Небольшие комментарии к командам можно вставлять прямо из командной строки. Комментарий вводится прямо в командную строку, после символов #^ или #v. Символы ^ и v показывают направление выбора команды, к которой относится комментарий: ^ - к предыдущей, v - к следующей. Например, если в командной строке было введено:

    $ whoami
    
    user
    
    $ #^ Интересно, кто я?
    
    в журнале это будет выглядеть так:
    $ whoami
    
    user
    
    Интересно, кто я?

  15. Если комментарий содержит несколько строк, его можно вставить в журнал следующим образом:

    $ whoami
    
    user
    
    $ cat > /dev/null #^ Интересно, кто я?
    
    Программа whoami выводит имя пользователя, под которым 
    мы зарегистрировались в системе.
    -
    Она не может ответить на вопрос о нашем назначении 
    в этом мире.
    
    В журнале это будет выглядеть так:
    $ whoami
    user
    
    Интересно, кто я?
    Программа whoami выводит имя пользователя, под которым
    мы зарегистрировались в системе.

    Она не может ответить на вопрос о нашем назначении
    в этом мире.
    Для разделения нескольких абзацев между собой используйте символ "-", один в строке.

  16. Комментарии, не относящиеся непосредственно ни к какой из команд, добавляются точно таким же способом, только вместо симолов #^ или #v нужно использовать символы #=

  17. Содержимое файла может быть показано в журнале. Для этого его нужно вывести с помощью программы cat. Если вывод команды отметить симоволами #!, содержимое файла будет показано в журнале в специально отведённой для этого секции.
  18. Для того чтобы вставить скриншот интересующего вас окна в журнал, нужно воспользоваться командой l3shot. После того как команда вызвана, нужно с помощью мыши выбрать окно, которое должно быть в журнале.
  19. Команды в журнале расположены в хронологическом порядке. Если две команды давались одна за другой, но на разных терминалах, в журнале они будут рядом, даже если они не имеют друг к другу никакого отношения.
    1
        2
    3   
        4
    
    Группы команд, выполненных на разных терминалах, разделяются специальной линией. Под этой линией в правом углу показано имя терминала, на котором выполнялись команды. Для того чтобы посмотреть команды только одного сенса, нужно щёкнуть по этому названию.

О программе

LiLaLo (L3) расшифровывается как Live Lab Log.
Программа разработана для повышения эффективности обучения Unix/Linux-системам.
(c) Игорь Чубин, 2004-2008

$Id$