Добавил:
Upload Опубликованный материал нарушает ваши авторские права? Сообщите нам.
Вуз: Предмет: Файл:

лекц+лаб по Windows

.pdf
Скачиваний:
5
Добавлен:
16.02.2016
Размер:
25.09 Mб
Скачать

 

Outpost Firewall):

 

(

 

 

 

 

 

1.

 

'

,

 

 

 

 

'

,

 

.

 

 

 

 

 

2.

 

'

 

ActiveX,

,

 

 

 

Web-

,

.

 

 

 

 

 

 

3.

 

 

'

 

 

 

Web-

,

 

 

,

 

 

4.

 

,

'

.

 

 

 

 

 

 

 

Java

VB

,

 

 

ARP-

,

 

 

 

,

 

.

 

5.

 

 

'

 

 

 

 

 

 

,

 

.

,

 

 

 

IP-

.

 

 

6.

 

 

'

,

 

 

 

 

 

Web-

,

 

 

 

 

«IP-

».

 

 

7.

Java-

 

'

 

 

 

 

 

,

 

,

 

8.

DoS

.

'

 

 

 

 

 

 

 

 

.exe-

,

 

 

,

 

 

 

,

.

 

,

 

,

 

 

 

 

 

 

9.

 

'

 

 

 

,

 

cookies

'

,

,

 

 

.

 

 

 

 

 

 

 

 

 

10.

 

'

 

 

 

.bat-

,

 

 

,

 

 

«

»

,

 

 

,

 

,

 

 

.

 

 

 

11.

 

'

,

 

 

 

 

 

 

 

 

12.

DNS

'

DNS

.

 

 

 

,

 

 

 

 

-

.

 

 

 

 

 

 

137

1.

.

2.

.

3.

.

4.

.

 

 

.

5.

.

.

,

,

138

10

Unix IPFW

IPFW Unix. IPFW,

,IPFW.

 

Unix

ipfw

 

ipfw,

:

.

 

 

 

 

 

ipfw [

_

] [set

_

_

]

[log]

 

 

'

 

 

_

1

65535,

 

 

 

 

 

,

. ,

.

,

.

,

.

 

inet.ip.fw.automatic_step,

100.

,

.

2.2 IPFW

-a

.

show

-d

 

 

-e

 

 

-f

,

flash

-N

 

'

-q

 

,

,

.

 

 

.

.

 

 

-

 

(pipes)

s[field]

.

 

-t

 

.

139

2.3

 

IPFW

 

 

Allow/accept/

 

 

 

.

pass/permit

 

 

 

 

check-state

 

 

 

.

 

 

,

,

'

 

.

,

check-state

,

 

 

 

(keep-state)

limit

,

 

Count

 

.

 

.

 

Deny/rop

 

.

 

 

 

 

divert port

 

,

 

 

Fwd/orward

,

, natd.

IP-

 

 

 

ipaddr[,port]

.

 

.

IP-

 

-

,

 

 

 

,

 

 

.

pipe pipe_nr

 

 

 

.

queue queue_nr

 

 

 

.

Reset

,

tcp

,

TCP RST

Skipto number

.

 

,

 

 

 

 

Tee port

,

,

.

 

.

 

 

Unreach code

ICMP

 

 

 

 

 

 

.

 

ICMP , 0 255. : net, host, protocol, port, needfrag, srcfail, net-unknown, hostunknown, isolated, net-prohib, host-prohib, tosnet, toshost, filter-

prohib, host-precedence or precedence-cutoff.

 

'

_

_

0

31,

31-

,

 

 

 

.

 

 

.

,

.

140

2.4

 

IPFW

 

Dst-ip

IP-

.

 

Src-ip

IP-

 

 

src-port

 

.

 

 

,

: udp, tcp.

 

dst-port

 

.

 

 

,

: udp, tcp.

 

established

 

TCP

ACK

RST.

 

 

 

Frag

.

,

,

 

 

 

/

,

ICMP-

 

 

.

 

In/ut

 

.

 

keep-state

 

 

 

' .

.

Proto

 

.

 

TCP, UDP

ICMP.

 

/etc/protocols.

recv

,

.

interface

 

 

xmit

 

.

interface

 

 

via

 

.

interface

 

 

Tcpflags

TCP

.

,

 

,

,

.

 

: fin, syn, rst, psh, ack, urg.

 

In/ut

.

 

1.IPFWUnix?

2.IPFW?

3.IPFW' ?

4.IPFW?

5.natd?

6.natd

 

.

7.

tcp

iptables?

.

141

8. icmp IPFW.

 

1.

 

 

 

 

 

 

 

 

 

,

 

 

 

 

 

'

.

 

 

2.

,

,

 

 

 

,

 

.

 

 

:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

ipfw add <

_

>

 

ipfw

 

 

 

 

 

 

:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

ipfw del <

_

>

 

 

 

 

 

 

 

3.

 

.

ipfw,

 

 

 

 

 

4.

,

 

 

 

 

 

'

,

 

 

 

 

 

:

 

 

 

ipfw add

_

count ip from

' _

_

 

_

to any

 

ipfw add

_

count ip from any to

' _

_

 

_

 

5.

 

 

 

 

,

 

 

:

 

ipfw show

_

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

(

 

 

 

 

 

 

):

 

 

 

 

 

1.

,

 

 

 

 

 

 

-

from any to any.

-

 

.

 

 

 

 

allow ip

 

 

 

 

 

 

 

 

DNS.

2.

 

ipfw

,

 

,

 

udp

 

 

 

 

53

-

 

 

 

udp

-

 

53

.

 

,

 

 

 

 

,

 

 

3.

-

 

.

 

'

.

 

 

 

 

 

 

 

 

 

 

ipfw

,

 

 

ip

 

 

 

 

 

4.

.

 

 

 

 

:

ping.

 

 

 

 

 

 

 

 

 

 

ipfw

,

 

 

 

icmp

-

 

 

 

,

0,3,5,8,11.

 

icmptypes

 

,

 

 

 

 

 

 

 

 

ping.

 

 

 

 

 

 

 

 

5.

ssh

web

'

.

 

 

 

ipfw

 

,

 

tcp

-

 

 

 

 

 

22 80.

 

,

 

 

 

 

 

sshd,

httpd

ssh.

 

 

 

 

web

,

 

 

 

, c

'

:

 

 

 

 

 

 

telnet <ip_Web> 80

 

 

 

 

 

 

 

142

6.

 

 

 

 

 

web

 

.

ftp.

 

ipfw

 

 

,

 

 

 

 

 

 

 

 

 

 

 

 

 

 

7.

 

tcp

20

21

 

.

 

 

http.

 

ipfw

 

 

,

 

 

 

 

 

 

tcp 80

.

 

 

 

 

 

8.

 

 

 

 

64

/c.

 

 

 

:

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

ipfw add

pipe

31 ip

from

any

to

' _

_

_

out

_

_

 

 

 

 

 

 

 

 

 

ipfw pipe 31 config 31 bw 64Kbit/s

 

 

 

ssh.

 

9.

ipfw

 

 

,

 

 

 

 

 

 

tcp 22

.

 

 

 

 

 

 

 

 

 

 

 

DoS (

 

10.

 

,

 

 

 

 

 

 

),

 

 

 

 

 

 

 

 

 

.

 

 

'

 

,

 

 

 

 

 

,

 

 

 

 

'

172.16.0.0

 

 

10 '

,

'

.

 

 

 

 

 

 

:

 

 

 

 

 

 

 

 

 

ipfw add allow tcp from

 

 

to any

_

_

 

setup limit src-addr 10

 

 

 

 

 

 

 

 

 

ipfw add allow tcp from any to

' _

_

 

_

limit src-addr 4

11.

 

ipfw

 

,

 

 

 

telnet.

tcp 23

 

 

 

 

 

 

.

 

 

 

 

 

 

 

SMTP.

12.

 

 

 

 

 

 

 

 

25

tcp

 

 

 

,

 

 

 

 

,

 

 

 

.

 

 

 

 

 

 

1.

.

 

 

 

 

 

 

 

 

 

2.

.

 

 

 

 

 

 

 

 

 

3.

 

 

 

 

.

 

 

 

ipfw,

 

4.

 

 

,

 

 

,

 

 

.

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

 

5.

.

 

 

 

 

 

 

 

 

 

143

 

:

 

 

 

 

 

 

 

 

 

/B

/

 

 

 

 

 

 

 

 

,

 

 

 

 

 

 

 

 

 

 

-

 

 

-

 

 

-

 

 

(

)

 

 

 

 

 

 

 

( ) '

( )

,

 

 

 

 

 

 

 

 

 

 

 

 

DNS Domain Name System (

)

HID Human interface device

 

OSI (

)

 

SDU

 

 

SMIB

 

 

TRS

MIB ISO/SEC

144