Guess what is this:
just some characters that does not mean anything or an useful message???
This is the whole purpose of encryption. If you cannot stop anyone to sniff your traffic (legitimate or illegitimate), we should make the message in a form that it can be understood by only you and the receiver.
What actually i have written above is:
How I did it?
I just incremented each letter, for example what comes after S is T, what comes after E is F and so on.......
so I can say I applied a logic of increment (can be denoted as + ),
I could also have taken what comes before S (R in that case) by applying the logic of decrement (can be denoted as - )
So Logic can be called as Algorithm
while the Factor by which the logic is applied can be called as Key
In both examples (S to T and S to R) the factor was 1, as we incremented or decremented by just one place.
If the KEY is 2 the increment logic will change the S to U, E to G and so on........... and the output will be UGEWTG.
Whenever to parties want to use encryption for their communication, they need to use a common algorithm (DES, 3DES, AES, etc), and a common key.
Remember algorithm is not a secret, we all know how DES/3DES/AES/other encryption algorithms work, so the whole security lies in the secrecy of key.
A software may support many algorithms and it can be negotiated on the network, while as the whole security is based on the secrecy of key if we negotiate the key on network and somebody is able to sniff it, the security is compromised.
So in case of Symmetric encryption the key need to be securely communicated preferably using some other communication channel e.g. via sms, phone, etc. Sending key using an alternate communication channel is called out-of-band delivery.
Once both parties possess the same key they can now use symmetric encryption.