ii
Contents
1. Intro...........................................................................................................................................1
2. What is a socket?.....................................................................................................................4
3.
struct
s and Data Handling...................................................................................................7
3.1. Convert the Natives!83.2. IP Addresses and How to Deal With Them8
4. System Calls or Bust..............................................................................................................11
4.1.
socket()
—Get the File Descriptor!114.2.
bind()
—What port am I on?114.3.
connect()
—Hey, you!134.4.
listen()
—Will somebody please call me?144.5.
accept()
—“Thank you for calling port 3490.”144.6.
send()
and
recv()
—Talk to me, baby!154.7.
sendto()
and
recvfrom()
—Talk to me, DGRAM-style164.8.
close()
and
shutdown()
—Get outta my face!174.9.
getpeername()
—Who are you?174.10.
gethostname()
—Who am I?184.11. DNS—You say “whitehouse.gov”, I say “63.161.169.137”18
5. Client-Server Background.....................................................................................................20
5.1. A Simple Stream Server205.2. A Simple Stream Client225.3. DatagramSockets23
6. Slightly Advanced Techniques..............................................................................................26
6.1. Blocking266.2.
7. Common Questions................................................................................................................45
Leave a Comment
Puis-je vous offrir a boire?
J'ai trouve un bon nombre de choses intresting ici.
i want to
you people need to get a life
Puis-je vous offrir a boire?
what is this all about?
very clearly expressed information
Il est DIFFICILE D'EMPLOYER bon contenu mais la navigation !