NachOS 3                        onTheore tical Presentati
What is networking?A collection of machines, links and switches set up so that machines cancommunicate with each other.Nac...
How it works?
Step 1Host A is telling the Gateway Server the following: "Id like to initiate a newconnection with you. My Sequence numbe...
Step 4.Host A generates a packet with some data and sends it to the Gateway Server.The data tells the Gateway Server which...
W hich files?First of all we have to implement Locks and ConditionVariablesWhich files should we modify?The files of impor...
●   nettest.cc: application to test communication between    host id 0 and host id 1machine directory:● network.h, network...
Security● EncryptionAll encryption is based on an algorithm, the function of thisalgorithm is basically encode the informa...
The encryption and decryption algorithms uses what is called key to encrypt or                           decrypt informati...
seudo-code (Server)     Pclass Server{    try{        ServerSocket ss = new ServerSocket(8080); /*Create    server*/      ...
seudo-code (Client)     Pclass Client{    try{        Socket s = new Socket("localhost", 8080); /*Create    socket*/      ...
Sources●   http://en.wikipedia.org/wiki/Acknowledgement_(data_networks)●   http://www.firewall.cx/networking-topics/65-tcp...
Nachos3 - Theoretical Part
Upcoming SlideShare
Loading in …5
×

Nachos3 - Theoretical Part

690 views

Published on

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
690
On SlideShare
0
From Embeds
0
Number of Embeds
142
Actions
Shares
0
Downloads
2
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Nachos3 - Theoretical Part

  1. 1. NachOS 3 onTheore tical Presentati
  2. 2. What is networking?A collection of machines, links and switches set up so that machines cancommunicate with each other.Nachos provides the abstraction of communication using mailboxes. The Nachosnetworking abstraction reaches to closely connected computers. The messaging isunreliable and messages can be dropped, but they are never corrupted in any way.The networking provides ordered and fixed-sized messages. There are severalclasses that builds the Nachos networking facility. 
  3. 3. How it works?
  4. 4. Step 1Host A is telling the Gateway Server the following: "Id like to initiate a newconnection with you. My Sequence number is 1293906975" Step 2The Gateway Server is telling Host A the following: "I acknowledge yoursequence number and expecting your next packet with sequence number1293906976. My sequence number is 3455719727".Step 3.Host A is telling the Gateway Server the following: "I acknowledge your lastpacket. This packets sequence number is1293906976, which is what youreexpecting. Ill also be expecting the next packet you send me to have a sequencenumber of3455719728". 
  5. 5. Step 4.Host A generates a packet with some data and sends it to the Gateway Server.The data tells the Gateway Server which webpage it would like sent.The sequence number of the segment in line 4 is the same as in line 3 becausethe ACK does not occupy sequence number space. 
  6. 6. W hich files?First of all we have to implement Locks and ConditionVariablesWhich files should we modify?The files of importance are:threads directory:● lockcond.h, lockcond.cc: for defining and implementing lock and condition synchronization primitives; needed for network applications to work.network directory:● post.h, post.cc: postoffice and mailbox, mail message definition and implementation.
  7. 7. ● nettest.cc: application to test communication between host id 0 and host id 1machine directory:● network.h, network.cc: Data structures to emulate a physical network connection. The network provides the abstraction of ordered, unreliable, fixed-size packet delivery to other machines on the network.● sysdep.h, sysdep.cc : Interprocess communication operations, for simulating the network; Unix sockets creation, binding, closing, etc. are called here to provide nachos socket functionality. 
  8. 8. Security● EncryptionAll encryption is based on an algorithm, the function of thisalgorithm is basically encode the information to beindecipherable at first sight.An encryption algorithm can transform the letter "A" to"5x5mBwE" or to "xQE9fq" and the work of an encryptionalgorithm is precisely determine how information will betransformed from its original state to one that is difficult todecode.
  9. 9. The encryption and decryption algorithms uses what is called key to encrypt or decrypt information.These keys are used to encrypt information, however, there is another key thatthe person who receives the message knows, and it is through this unique key that the message can be decrypted.
  10. 10. seudo-code (Server) Pclass Server{ try{ ServerSocket ss = new ServerSocket(8080); /*Create server*/ Socket s = ss.acept(); /* Create socket */ receiveString(); decodeString(); s.close(); /* Close connection */ ss.close(); } catch(Exception ex){ ex.printStackTrace();}}//End of Server
  11. 11. seudo-code (Client) Pclass Client{ try{ Socket s = new Socket("localhost", 8080); /*Create socket*/ encodeString(); /*before send String data must beencode*/ sendString(); s.close(); } catch(Exception ex){ ex.printStackTrace(); }}//End of Client
  12. 12. Sources● http://en.wikipedia.org/wiki/Acknowledgement_(data_networks)● http://www.firewall.cx/networking-topics/65-tcp-protocol-analysis/134-tcp- seq-ack-numbers.html● http://cnx.org/content/m30811/latest/● http://cnx.org/content/m30811/latest/ For more information go to blog: www.os-ocj.blogspot.com

×