Advertisement
Guest User

Untitled

a guest
Nov 20th, 2019
121
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 14.68 KB | None | 0 0
  1. zad1
  2. a) Połączyć ze wszystkimi hostami wirtualnymi.
  3.  
  4. GET /index.html HTTP/1.1
  5. host: student.pl
  6.  
  7. HTTP/1.1 200 OK
  8. Date: Wed, 06 Nov 2019 07:21:44 GMT
  9. Server: Apache/2.4.41 (Win32) OpenSSL/1.0.2s
  10. Last-Modified: Tue, 07 Nov 2017 09:34:32 GMT
  11. ETag: "51-55d61473dda00"
  12. Accept-Ranges: bytes
  13. Content-Length: 81
  14. Content-Type: text/html
  15.  
  16. Hej! Znajdujesz się na stronie (student.pl) alias www.student.pl plik index.html
  17.  
  18.  
  19. GET /index.html HTTP/1.1
  20. host: wykladowca.pl
  21.  
  22. HTTP/1.1 401 Authorization Required
  23. Date: Wed, 06 Nov 2019 07:22:59 GMT
  24. Server: Apache/2.4.41 (Win32) OpenSSL/1.0.2s
  25. WWW-Authenticate: Basic realm="Podaj has▒o"
  26. Content-Length: 401
  27. Connection: close
  28. Content-Type: text/html
  29.  
  30. <!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
  31. <html><head>
  32. <title>401 Authorization Required</title>
  33. </head><body>
  34. <h1>Authorization Required</h1>
  35. <p>This server could not verify that you
  36. are authorized to access the document
  37. requested. Either you supplied the wrong
  38. credentials (e.g., bad password), or your
  39. browser doesn't understand how to supply
  40. the credentials required.</p>
  41. </body></html>
  42.  
  43. ---------------------------------------------------------------
  44.  
  45. b) Pobrać stronne index.html
  46.  
  47. GET /index.html HTTP/1.1
  48. host: student.pl
  49.  
  50. HTTP/1.1 200 OK
  51. Date: Wed, 06 Nov 2019 07:25:24 GMT
  52. Server: Apache/2.4.41 (Win32) OpenSSL/1.0.2s
  53. Last-Modified: Tue, 07 Nov 2017 09:34:32 GMT
  54. ETag: "51-55d61473dda00"
  55. Accept-Ranges: bytes
  56. Content-Length: 81
  57. Content-Type: text/html
  58.  
  59. Hej! Znajdujesz się na stronie (student.pl) alias www.student.pl plik index.html
  60.  
  61. Pobrać stronę zabezpieczoną na hasło.
  62.  
  63. GET /index.html HTTP/1.1
  64. host: wykladowca.pl
  65. Authorization: Basic d3lrbGFkb3djYTp3eWtsYWRvd2Nh
  66.  
  67. HTTP/1.1 200 OK
  68. Date: Wed, 06 Nov 2019 07:36:58 GMT
  69. Server: Apache/2.4.41 (Win32) OpenSSL/1.0.2s
  70. Last-Modified: Tue, 07 Nov 2017 09:35:18 GMT
  71. ETag: "58-55d6149fbc180"
  72. Accept-Ranges: bytes
  73. Content-Length: 88
  74. Content-Type: text/html
  75.  
  76. Hej! Znajdujesz się na stronie (wykladowca.pl) alias www.wykladowca.pl plik in dex.html
  77.  
  78. ---------------------------------------------------------------
  79.  
  80. c) Pobrać stronę, która nie istnieje na serwerze i odczytać kod błędu.
  81.  
  82.  
  83. GET /fake.html HTTP/1.1
  84. host: student.pl
  85.  
  86. HTTP/1.1 404 Not Found
  87. Date: Wed, 06 Nov 2019 07:40:22 GMT
  88. Server: Apache/2.4.41 (Win32) OpenSSL/1.0.2s
  89. Last-Modified: Tue, 22 Nov 2011 10:08:00 GMT
  90. ETag: "67-4b24ffa662000"
  91. Accept-Ranges: bytes
  92. Content-Length: 103
  93. Content-Type: text/html
  94.  
  95. Hej! Znajdujesz się na stronie www.student.pl <br><br>
  96.  
  97. <B>Niestety nastšpił błšd <h1>404</h1></b>
  98.  
  99. KOD BLEDU: 404
  100.  
  101. ---------------------------------------------------------------
  102.  
  103. d) Pobrać tylko nagłówek odpowiedzi z serwera.
  104.  
  105. HEAD /index.html HTTP/1.1
  106. host: student.pl
  107.  
  108. HTTP/1.1 200 OK
  109. Date: Wed, 06 Nov 2019 07:42:49 GMT
  110. Server: Apache/2.4.41 (Win32) OpenSSL/1.0.2s
  111. Last-Modified: Tue, 07 Nov 2017 09:34:32 GMT
  112. ETag: "51-55d61473dda00"
  113. Accept-Ranges: bytes
  114. Content-Length: 81
  115. Content-Type: text/html
  116.  
  117. ---------------------------------------------------------------
  118.  
  119. e) Sprawdzenie ważności strony. Sprawdzić, jakie jest pole Last-Modified
  120.  
  121. ---------------------------------------------------------------
  122.  
  123. f) Pobrać rysunek a1.gif
  124.  
  125. GET /a1.gif HTTP/1.1
  126. host: student.pl
  127.  
  128. HTTP/1.1 200 OK
  129. Date: Wed, 06 Nov 2019 07:45:57 GMT
  130. Server: Apache/2.4.41 (Win32) OpenSSL/1.0.2s
  131. Last-Modified: Fri, 26 Apr 2002 09:21:14 GMT
  132. ETag: "1524-39f83b0179680"
  133. Accept-Ranges: bytes
  134. Content-Length: 5412
  135. Content-Type: image/gif
  136.  
  137.  
  138. GIF89a÷ccc˙11111c1cccccc11cccccccccksĽĽ{ĽĽ{­­ľľľľc1ν˝ÎÎĽĆĆľÎνÖÖĆĆĆĆÖÖĆŢŢÎ1ÎÎÎÎÎÎŢŢÖççŢďďçďďď÷÷÷÷÷÷˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙˙ţH° *\Č°ĄĂ#JHą˘Ĺ3jÜČąŁÇ CI˛¤É(SŞ\ɲĽË0cĘISĽ5sęÜiň&7y
  139. JT˘ĎH]ĘtŠ¤PhJľjMD*`ŞŐpÁ͡h×Ęp\KNź¸˛U'ěâ
  140. CKV`š4SĚÇĺ,ÂóŔ
  141. 0`F|´éŰB5`:ëÎ>Ç}xď^۸çÔ­Ąšóć
  142. ĂřqĺŘŘÎ]zAŘÔ­ţ×ÎNžŚn˝ÔŤ[G^ž}Ë
  143. đ3ĚčrzńěÝëG ž
  144. ř3'fŕĹś^kű%Čü'kťíe`m ÔŕÁF
  145. đV á$mŘ Ě=ç\t(îÔh#¨ĽČ]w1ćäA D#9~ľŁ=zxĄeEŁGéB9@ViĐfPÂ'  ŃöPuTTYŐYfŮofÉ$S.ů"ńUYhU2
  146. ¤k#ę[čąÜî8WgőZkă:[Žš-Ü˝vßzT}eęÄ\|b*şčzÂPĂl×5Uc jşévţEE?ÚŠ_J[Ş~Ň)Žś ˇÖ$ëŹČÚjZ7éP_F@c]śš$
  147. ´iş| ëR˘ţh¨\cdŻgáÍúŹ$ 8Vî°ŮŠĄA"R7`lÎ r
  148. ¨î´ZťdŔk
  149. Rg 3łö^
  150. 5Đ02É~FpîÉëFÜnË.{TĚHÓÁ˝K
  151. Hw03u$<_ÎOĚŔąr7qÖ3Îxąť]ŇaČţ"ßűtÚjłMÓŔôüĺnˇËrÝv-łŘIďšČó0ŕţBz"c^|BĂ
  152. ˝$×_äŢ"@ôä}[NŔô;ZC0lę)>Îşń°p/@Ô$ßkHún n×č đđÄkx|ëxONň0ď|ŮkĎÄ]ďđwž]ö˝gĎćdpá?´?âóL¸
  153. śńoç
  154. <ç­MzÓŤÁč5ŘI?Q
  155. Đéâ+)ŠÝ ě'AJQT$ŔHÖĎ<šd%iŠĚ=.s'
  156. Nt¤ůŁćyq4ä!eRCEv&ťÉŕöúLrqü%-#M鸨Äf6ľÉFn&R>ţ¤ü(ž´s WH@Ń8ĎQ2¨Ůçőާ=
  157. Ž/.XA@ò#ď0
  158. tŢA]"ł#zsYÁV°EÄđÍN&ŞH¤ýiFTđRÚÔ".
  159. éMw
  160. ާ@u
  161. &đÓ 5!9eéŕĚ;#Tt:<ĄŠN=hB/R2ŞkD ËX!bľJNKŻ>ÓŹCĄ\IV´śľŹë
  162. ]_éĚ0Î'>eŤ$iŐKŢ5~}ëXKX§Ţqd}Ś2s2Ô˘îDćLgW]éLĹNV"ľŞbӚ̞îąX%IRË9ŘŃó~đQ+2á
  163. ˤ˛2Éđ/Ňá$xÁ,ńILá&+°WĂřˇä­@PLcŘŘ%ZuÉ
  164. *`÷ŘÇ-˛sźă#säÇ+špJÜd'?9É+ąJ\d+{Ę(9ń-Pe/wĚ&Ńrţtuld3cÍŞĹqI¸Üf7żËióH¨\g;ßŮĂs^rIRŔf?Î rHR0ôŮĐ5ĆłHÔźč |@Ŕ>ł¤-čJ_:Ó&A4G(íÔĄŢtGÍScŐPuTTYPuTTYPuTTYőLőźWĂ:%˛žKméWß$šŤ1bë_Ť$Ř!5ą{ml ;"ťÖ
  165. ÝlgŤ§]Ö¨]mk:#ž~
  166. úŘOţś÷ÓŞTą!ąöđ{ˇ%n)ŮvJ@&_SóOţGÎđĎ8ŔőînúÚ/Ůö{Ü(ý˛ÖpD,-mŕ?§ć>Ůú70đ;şă?ÉęgÔzşýřŻÁŔ$űš'7ťWů'á]ÂzŰ!` ÎťŔ\fEśˇľ nçz}ćN÷ş[ âŇ*Ö˝­
  167. 8@řŘX  ¨~ď7$ęŽq8ű,h7\!~Č+xďr!<h>h@¸Ex
  168. _1
  169. 4¸0?Č
  170. T1
  171. Czág
  172. TxVh˝Z¸
  173. %Ń `=5Ré¸nć
  174. *Č" hj¸lŘnhW´őč$Zo¨Ě%sh}nČJöuŚUGýCNč^L%WuřGúő^Q>'ݸóľá^(DŮzřU×) ľÇsNń¨]?^{YH×ŐąaÇö¨řŔýřIiyzÉaőéŠ1onXň6mČHćŰ(#i&šŠm šţ(\
  175. (ů/ +3Ii'Ů#A
  176. HEšWv,¨KIGéIéaFăYI
  177. \ŮLkHIwa)Růeeůsg%!2×nůk)pr9tŠ&wx×Ç}éś)
  178. G
  179. ľiAĆľ)¨IĂIA5ţđÓńĐé1)XŇbrÍ)ĎáŢiŁóuőiâ˝s ŤćéĆšę  źá"jÝ)ÖÓ 
  180. J
  181. şiďôNÚ&8s$'& !bĄÜ)ňŮĄÁ÷Ů`ŚWPWs&ą8"éŇ$+Ę=.q 7Ł4ş 2eĹ1go5đ J˘MJa0ő¤5ŕѢőáqŞ%X˘ę)& s(ńqĄJ
  182. ŚaJvç!%ôůo>:ĽĆYÖ2jc¤ńštEQŁ
  183. ú˘]§Ę¤;áâwŚńđI%8c|ă4=¸
  184. PsÔŮ&_q39ł3%ăúĘ`ę?57ĽGŇŚüiM6uTTYg*~ŃD Š*OÚŞ2Ź5đpT¨UÁ5QÓ>ďÉĽ!ŇĎ8
  185. Ź MđAr˛z˘Č*2ĐVÇŹŞPâĘŤÂŞż
  186. PŃqţ¨ćy˘BÚ
  187. ´RË{lZą¨şTáŤę?ÔĘŽą­Ua°.°Đł°QĽ KdęYŇz/;í$a"ëţxlóŞZzK­úúułz.3Ť¨ávZ­VťGŇ/ąędT´
  188. áąČ fzęZ¨Ë[ű°ĄĽëzśĆúŚ*Áśĺ9Ź3ţÉqëTđɡűłEaQzŰąÔůŁ".Ť{2|á ŹÓ!3Iő>Őʡnű¸Q¤úśĆŠś-)ň04ý"3ËŻů=:šTšťůˇŰŁ&ęˇk*¨2ĺťU
  189. ťVq­Ĺ
  190. ´Ä[ź(ţëť@źÉB.ÍkťSšj˛¨Ť; U
  191. Ťg4Đť4ztý˝Â[JżęTk&Ť)§0ńžŢK´lęźi;ž^"uK0ÍŃŔż
  192. ˝Ŕ[ż%!ŔúR
  193. žHşŃ
  194. ŞČ
  195. ń UňS\hĚ~Ë Z
  196. lVŠłĚ"ÔŻúÄQLÁáĘkAN
  197. ˘čČślTŃÝŁZlA
  198. vöÓô´QÄĚÍâ[VŃföÓ@Ô×K¸2Ă\ľF1tP;,PÔ[-ePŤÁ!Ń˝ĹŘ^˘ŹŘ
  199. LňQőDŔzÉ2ĂÁçĎŻÜĐťlÉUţÎuYVąŃÚ´Qľ;ż\Ď
  200. ĘŤhIH˘lĚĄ<Ęʸ^-ńËÄŠĎŘČžěKÁŰžaĎşýť,Ρ\ĺhÍűě
  201.  
  202. Ü)y8 °fŮÍWúĚE]U
  203. jř<W
  204. í×@ ,ż=ŮśuĎÄM[ţl+ËĎÜÖŃ}ÝŘ
  205. ÎEUxŮz­\.ÁĐşLФ|gĚß<\śÍÎ=Iö
  206.  
  207.  
  208. ---------------------------------------------------------------
  209. ZAD2
  210.  
  211. a.Rozesłać listu do wszystkich uczestników zajęć.
  212.  
  213. 220 DESKTOP-8C77PU7.poczta.student.pl ESMTP MailEnable Service, Version: 10.27-- ready at 11/06/19 08:54:38
  214. hello student.pl
  215. 503 Bad sequence of commands
  216. helo student.pl
  217. 250 Requested mail action okay, completed
  218. mail from: <pai05@poczta.student.pl>
  219. 250 Requested mail action okay, completed
  220. rcpt to: <pai01@poczta.student.pl>
  221. 250 Requested mail action okay, completed
  222. rcpt to: <pai02@poczta.student.pl>
  223. 250 Requested mail action okay, completed
  224. rcpt to: <pai03@poczta.student.pl>
  225. 250 Requested mail action okay, completed
  226. rcpt to: <pai04@poczta.student.pl>
  227. 250 Requested mail action okay, completed
  228. rcpt to: <pai06@poczta.student.pl>
  229. 250 Requested mail action okay, completed
  230. rcpt to: <pai07@poczta.student.pl>
  231. 250 Requested mail action okay, completed
  232. rcpt to: <pai08@poczta.student.pl>
  233. 250 Requested mail action okay, completed
  234. data
  235. 354 Start mail input; end with <CRLF>.<CRLF>
  236. Jarek Spyrka
  237.  
  238.  
  239.  
  240.  
  241. .
  242. .
  243. 250 Requested mail action okay, completed
  244.  
  245.  
  246. quit
  247. 221 Service closing transmission channel
  248.  
  249. ---------------------------------------------------------------
  250.  
  251. b. Wysłać list do nieistniejącego użytkownika
  252.  
  253. rcpt to: <fake@poczta.student.pl>
  254. 550 Requested action not taken: mailbox unavailable or not local.
  255.  
  256. **************
  257. c. Wysłać list od nieistniejącego użytkownika.
  258.  
  259.  
  260. helo student.pl
  261. 250 Requested mail action okay, completed
  262.  
  263.  
  264. mail from: <fake@poczta.student.pl>
  265. 250 Requested mail action okay, completed
  266. rcpt to: <pai04@poczta.student.pl>
  267. 250 Requested mail action okay, completed
  268. data
  269. 354 Start mail input; end with <CRLF>.<CRLF>
  270. fake jarek.
  271.  
  272. .
  273. 250 Requested mail action okay, completed
  274. quit
  275. 221 Service closi
  276.  
  277. ---------------------------------------------------------------
  278.  
  279. d. Wysłać list z polami nagłówka
  280.  
  281.  
  282. 220 DESKTOP-8C77PU7.poczta.student.pl ESMTP MailEnable Service, Version: 10.27-- ready at 11/06/19 09:00:32
  283. helo student.pl
  284. 250 Requested mail action okay, completed
  285. mail from: <pai06@poczta.student.pl>
  286. 250 Requested mail action okay, completed
  287. rcpt to: <pai01@poczta.student.pl>
  288. 250 Requested mail action okay, completed
  289. data
  290. 354 Start mail input; end with <CRLF>.<CRLF>
  291. Subject:Pai2019
  292.  
  293. TEST nAGLOWKA
  294.  
  295. .
  296. 250 Requested mail action okay, completed
  297.  
  298. 503 Bad sequence of commands
  299. quit
  300. 221 Service closing transmission channel
  301.  
  302.  
  303. ---------------------------------------------------------------
  304.  
  305. e. Sprawdzić zawartość swojej skrzynki odbiorczej
  306.  
  307. +OK Welcome to MailEnable POP3 Server
  308. user pai05
  309. +OK
  310. pass pai05
  311. +OK
  312. stat
  313. +OK 7 1384
  314. list
  315. +OK 7 1384
  316. 1 198
  317. 2 257
  318. 3 186
  319. 4 186
  320. 5 177
  321. 6 194
  322. 7 186
  323. .
  324. retr 1
  325. +OK 186 octets
  326. Received: from student.pl ([10.0.0.163]) by poczta.student.pl with
  327. MailEnable ESMTP; Wed, 6 Nov 2019 08:30:48 +0100
  328. Testowa tresc emaila KK
  329. Return-Path: <pai07@poczta.student.pl>
  330.  
  331. ---------------------------------------------------------------
  332. f. Odczytać nagłówki listów.
  333.  
  334.  
  335.  
  336. top 1
  337. +OK
  338. Received: from student.pl ([10.0.0.163]) by poczta.student.pl with
  339. MailEnable ESMTP; Wed, 6 Nov 2019 08:30:48 +0100
  340. Mikolaj i Vlad
  341. Return-Path: <pai06@poczta.student.pl>
  342.  
  343.  
  344. ---------------------------------------------------------------
  345.  
  346. g. Spróbować przeczytać nieistniejący list.
  347.  
  348. retr 15
  349. -ERR No such message
  350.  
  351.  
  352. ---------------------------------------------------------------
  353. h. Usunąć listy
  354.  
  355. list
  356. +OK 7 1384
  357. 1 198
  358. 2 257
  359. 3 186
  360. 4 186
  361. 5 177
  362. 6 194
  363. 7 186
  364. .
  365. dele 1
  366. +OK
  367. list
  368. +OK 6 1198
  369. 2 257
  370. 3 186
  371. 4 186
  372. 5 177
  373. 6 194
  374. 7 186
  375. .
  376.  
  377.  
  378. ---------------------------------------------------------------
  379.  
  380.  
  381. 3. Połączyć się protokołem FTP z serwerem ftp (Klient usługi).
  382. a. Przetestować działanie podstawowych komend protokołu ftp.
  383.  
  384. Microsoft Windows [Version 10.0.18362.418]
  385. (c) 2019 Microsoft Corporation. Wszelkie prawa zastrzeżone.
  386.  
  387. C:\Windows\system32>ftp
  388. ftp> open 10.0.0.4 21
  389. Connected to 10.0.0.4.
  390. 220-FileZilla Server 0.9.60 beta
  391. 220-written by Tim Kosse (tim.kosse@filezilla-project.org)
  392. 220 Please visit https://filezilla-project.org/
  393. 202 UTF8 mode is always enabled. No need to send this command.
  394. User (10.0.0.4:(none)): pai05
  395. 331 Password required for pai05
  396. Password:
  397. 230 Logged on
  398. ftp> ls
  399. 200 Port command successful
  400. 150 Opening data channel for directory listing of "/"
  401. 226 Successfully transferred "/"
  402. ftp> status
  403. Connected to 10.0.0.4.
  404. Type: ascii; Verbose: On ; Bell: Off ; Prompting: On ; Globbing: On
  405. Debugging: Off ; Hash mark printing: Off .
  406. ftp>
  407. ftp> mkdir qwe
  408. 257 "/test" created successfully
  409. ftp> cd test
  410. 250 CWD successful. "/test" is current directory.
  411. ftp> quit
  412. 221 Goodbye
  413.  
  414. C:\Windows\system32>
  415.  
  416.  
  417. ---------------------------------------------------------------
  418.  
  419. b) Przesłać plik na serwer
  420.  
  421.  
  422. C:\Users\student\Desktop>ftp
  423. ftp> open 10.0.0.4 21
  424. Connected to 10.0.0.4.
  425. 220-FileZilla Server 0.9.60 beta
  426. 220-written by Tim Kosse (tim.kosse@filezilla-project.org)
  427. 220 Please visit https://filezilla-project.org/
  428. 202 UTF8 mode is always enabled. No need to send this command.
  429. User (10.0.0.4:(none)): pai05
  430. 331 Password required for pai05
  431. Password:
  432. 230 Logged on
  433. ftp> send test.txt plik.txt
  434. 200 Port command successful
  435. 150 Opening data channel for file upload to server of "/plik.txt"
  436. 226 Successfully transferred "/plik.txt"
  437. ftp> ls
  438. 200 Port command successful
  439. 150 Opening data channel for directory listing of "/"
  440. plik.txt
  441. test
  442. 226 Successfully transferred "/"
  443. ftp: 18 bytes received in 0.00Seconds 18000.00Kbytes/sec.
  444. ftp> quit
  445. 221 Goodbye
  446.  
  447. ---------------------------------------------------------------
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement