공부공부 공부공부내용
네트워크 기초정리 3 본문
어제정리(13일자)
부트는 넘어가고
DNS 서버(대부분 서버)
내부 ip주소 호출을 위한arp 사용
DNS는 트리구조 - 계층화된 호출
77쪽DNS _ 재귀질의 순환질의
순환질의
-> student@kickseed:~$ dig @168.126.63.1 yahoo.co.kr +trace
재귀
->
student@kickseed:~$ nslookup
> server 168.126.63.1
Default server: 168.126.63.1
Address: 168.126.63.1#53
> yahoo.co.kr
Server: 168.126.63.1
Address: 168.126.63.1#53
Non-authoritative answer:
Name: yahoo.co.kr
Address: 98.136.103.23
Name: yahoo.co.kr
Address: 74.6.136.150
Name: yahoo.co.kr
Address: 212.82.100.150
---------------
5/14 수업내용
-FTP -> 다른 운영체ㅔㅈㅔ와 다르게 포트를 두개이상 사용한다.
FTP는 인증 포트 _ 인증,식별,인가
active 모드, passive 모드 (21번으로 인증) 이후 데이터전송이 active passive 로 각각 나뉨
사용자 요청에 따른 각각의 포트를 사용
active모드 _
passive모드 단점 _ 포트가 많이 낭비됨 (범위를 정해줄 필요가 있다)
각각의 포트를 한개씩 씀 ,쉽게고갈
무슨포트로 데이터를 받아갔는지 그래서 그게 active와 passive중 어떤 모드인지 wireshark로 확인
ip.addr == 192.168.0.181 && (tcp.port == 21 || tcp.port ==20)
sudo wireshak 열고 새창 열어서
student@kickseed:~$ ftp 192.168.0.175
Connected to 192.168.0.175.
220 (vsFTPd 3.0.3)
Name (192.168.0.175:student): student
331 Please specify the password.
Password:
230 Login successful.
Remote system type is UNIX.
Using binary mode to transfer files.
ftp> ls
200 PORT command successful. Consider using PASV.
150 Here comes the directory listing.
drwxr-xr-x 4 1000 1000 4096 May 09 19:06 CCCR_Class
drwxr-xr-x 2 1000 1000 4096 May 11 09:17 Desktop
drwxr-xr-x 2 1000 1000 4096 May 12 18:16 Documents
drwxr-xr-x 3 1000 1000 4096 May 13 16:53 Downloads
drwxr-xr-x 2 1000 1000 4096 May 08 16:36 Music
drwxr-xr-x 2 1000 1000 4096 May 08 16:36 Pictures
drwxr-xr-x 2 1000 1000 4096 May 08 16:36 Public
drwxr-xr-x 2 1000 1000 4096 May 08 16:36 Templates
drwxr-xr-x 2 1000 1000 4096 May 08 16:36 Videos
drwx------ 3 1000 1000 4096 May 11 17:48 VirtualBox VMs
-rw-r--r-- 1 1000 1000 8980 May 08 16:16 examples.desktop
drwxr-xr-x 3 1000 1000 4096 May 12 10:32 snap
-rw-r--r-- 1 1000 1000 3 May 14 10:18 test.txt
226 Directory send OK.
ftp> get.test.txt
?Invalid command
ftp> get test.txt
local: test.txt remote: test.txt
200 PORT command successful. Consider using PASV.
150 Opening BINARY mode data connection for test.txt (3 bytes).
226 Transfer complete.
3 bytes received in 0.00 secs (18.7800 kB/s)
ftp> exit
221 Goodbye.
ftp는 21번포트로 인증을 하고(3handshake 후)
active모드는 ㄹftp데이터 모드가 20번으로 동작을 하고
ftp는 서버 낭비가 심해서 passive로사용하는데
사설ip에서 데이터를 받아갈 수가 없다는 단점이 있다.
https://kimhyun2017.tistory.com/202 ->중요 wireshark 확인
1. PASSIVE MODE
패시브 모드는 기본 모드로서, 클라이언트는 랜덤한 포트로 접속하고 서버는 21번의 포트로 제어 및 접속을 위한 명령어를 전달한다.
그리고 데이터를 전송할 때는 서로 랜덤한 포트로 클라이언트가 서버에 데이터를 가져오거나 데이터를 준다. 이 과정을 WIRESHARK로 살펴보면 다음과 같다.
*ssh
one way function
일방향함수(一方向函數, one-way function)는 계산하기는 쉽지만 역을 구하는 것은 어려운 함수이다. 다시 말해서, 결과값이 주어졌을 때 입력값을 구하는 것이 어려운 함수이다. 물론 '쉽다', '어렵다'는 의미도 수학적으로 엄밀히 정의해야 한다. 공개 키 암호 방식은 극히 일부의 예외를 제외하면 모두 일방향함수가 존재한다는 가정 위에 연구되어 왔다.
-SET
-전자서명
-SSH
-SSL
-RSA
-SSL/TLS차이
*** 대칭형 암호와 , 비대칭형 암호화
공개키 암호화 방식 및 개인키 암호화방식 -> ssh // 키분배문제
STATIC ROUTING
#interface set
<R1> 10.100.1.0/24
enable
configure terminal
interface serial 0/0
ip adress 1.1.12.2 255.255.255.0
interface fastethernet 0/0
ip adress 10.100.1.254 255.255.255.0
<R2> 172.31.2.0/24
enable
configure terminal
interface serial 0/0
ip address 1.1.23.1 255.255.255.0
interface serial 0/1
ip address 1.1.12.2 255.255.255.0
interface fastethernet 0/0
ip address 172.31.2.254 255.255.255.0
interface fastethernet 0/0
ip address 10.100.1.254 255.255.255.0
duplex auto
speed auto
ip route 10.100.1.0 255.255.255.0 1.1.12.2
ip route 192.168.10.0 255.255.255.0 1.1.23.1
no shutdown
<R3>192.168.10.0/24
enable
configure terminal
interface serial 0/0
ip address 1.1.12.1 255.255.255.0
interface 10.100.1.254
ip route 172.31.2.0 255.255.055.0 1.1.12.1
ip route 1.1.23.0 255.255.255.0 1.1.12.1
ip route 10.100.1.0 255.255.255.0 1.1.23.1
#route table setting (static route)
<R1>
<R1>
<R2>
<R3>
<밴드 정리된거 다시ㅏ 참조>
https://m.blog.naver.com/PostView.nhn?blogId=demonicws&logNo=40108478294&proxyReferer=https:%2F%2Fwww.google.com%2F ***********************
'IT 기초, 네트워크, 리눅스 > 1. 네트워크' 카테고리의 다른 글
2일차 (0) | 2020.07.19 |
---|---|
네트워크 1일차 (0) | 2020.07.19 |
네트워크 정리4 (0) | 2020.06.07 |
네트워크 기초 정리 2 (0) | 2020.06.07 |
네트워크 기초 정리 1 (0) | 2020.06.07 |