1 / 8

CHAPTER 3 소켓 주소 구조체 다루기

CHAPTER 3 소켓 주소 구조체 다루기. Lab 2. Question 1. Try to convert Host Byte <-> Network Byte using hton*() & ntoh*() Try to use Winsock API (refer text book page 72) WSAHton*() WSANtoh*(). u_short i = 0x1357 u_long j = 0x12345678;. Sample Output Question 1. Question 2.

faith
Download Presentation

CHAPTER 3 소켓 주소 구조체 다루기

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. CHAPTER 3소켓 주소 구조체 다루기 u-Network Design Lab 2

  2. Question 1 • Try to convert Host Byte <-> Network Byte using hton*() & ntoh*() • Try to use Winsock API (refer text book page 72) • WSAHton*() • WSANtoh*() u_short i = 0x1357 u_long j = 0x12345678; u-Network Design

  3. Sample Output Question 1 u-Network Design

  4. Question 2 • Given a Domain Name, return ALL IP Addresses and aliases of the domain name. • Try Domain Name: • www.google.com • www.microsoft.com u-Network Design

  5. Sample Output Question 2 u-Network Design

  6. Question 3 • Converts an IP address in ASCII dotted-decimal format to 32-bit binary format • Converts 32-bit binary format (network byte ordering) back to IP address in ASCII dotted-decimal format IP Address: 218.94.56.119 u-Network Design

  7. Sample Output Question 3 u-Network Design

  8. Thank you u-Network Design

More Related