Posts

OSI Model

Image
  -application layer that what you interface with it, as you a backend or  frontend engneering like http protocol here it responseable to preparing the payload data all data i have to send (get req , header ,... ) then i have a chunk of data  -presentation layer  : serializtion and  encrypting and decrypting  -session layer maintains the connection and It distinguishes between the connections it  makes with different devices  -transport layer :  deal with application port  ,what the port that where you go ,what the port the you had come from (why you asking becauuse we need it for response from server )  and those things add , and  the chunk become a segments  and add sequence numbers to make they able to sort like they were -then network :  ip protocol deal with ip  ,add destination ip adress and source ip adress to the segments and we call it packets  -the second layer data link  : it add destination ...

Public IP vs. Private IP and Port Forwarding

Image
  If you check the picture, you will actually understand the difference between public ip and private ip public ip  : is used to access the global internet  private ip : is used to access the local internet  which consists of the router and the devices connected to the network If you are within the local network, it is easy to access the rest of the devices in the same network   If you are in the external network, access is possible only through the public ip of the router, and yet some details remain missing because all devices within the internal network are   accessed  through the public ip of the router, so how does the router know which device will be accessed?  One of the techniques to solve this problem is Port forwarding We know that every router has a forwarding TABLE, by which packets are forwarded in the network So all we have to do is tell the router that for a connection on port xxxx, access an address in the internal network that we ...