0

Sequence of preparing packets - Networking

Hello, As we all know, data that is being sent over the internet should be encrypted. The data is obviously encoded into bits, that's how data transfers over the internet. And another thing, the data is not being sent in ONE HUGE PACKET, it's going through a segmentation process that divides the data to small packets. Now to my question, What do we do first? Encrypt, encode, segmentation? Or an other order? Thanks (also fix me if I'm wrong in my intro).

4th Aug 2022, 9:15 PM
Yahel
Yahel - avatar
4 Respostas
+ 1
The data is handled independently from the segmentation and packetization. 1. Encrypt. 2. Segment. 3. Encode You could swap 1 & 2 in the opposite order, as long as encryption does not increase the size of the segment. If your packet encoding is also to be encrypted, then that is another step, but it would not be standard protocol to encrypt the whole packet.
4th Aug 2022, 10:39 PM
Brian
Brian - avatar
+ 2
Should research 'The OSI Model' to understand the topology of network function. The segmentation of the packets is done in layer 3. The TCP/IP layer where whatever bytestream is addressed and split apart (in tcp packets if applicable) via windowing. TCP is a stateful protocol. The encryption occurs in an application layer above the more fundamental layer 3. So though the packets are encrypted and segmented whatever is encrypting the bytestream is not in control of the segmentation except layer 3 controls the flow of packets and the byte stream Seriously read about the OSI model. Encryption doesnt occur within the bottom 3 layers. Which handle the machine of the network.
5th Aug 2022, 5:22 AM
ρү૨œdԌ૨ ×
ρү૨œdԌ૨ × - avatar
0
There is also something called the MTU or maximum transfer unit which in a network interface is configured to allow a maximum byte size in 1 packet as a buffer. Ive done some cool tricks with MTU value before for latency issues and more. The sockets sending application data to a NIC device node will be applications on various application layers doing your encryption. Research OSI model.
5th Aug 2022, 5:26 AM
ρү૨œdԌ૨ ×
ρү૨œdԌ૨ × - avatar
0
Also watch videos by 'Eli the computer guy' on youtube if you need to learn these things about core networking. Highly recommended.
5th Aug 2022, 5:29 AM
ρү૨œdԌ૨ ×
ρү૨œdԌ૨ × - avatar