Example of functions to encrypt/decrypt text

Hello everyone.

I had left this for a while and the other day I started making some functions to encrypt/decrypt text that I saw a while ago and used in some programs that I have made. Now I come here to show you in case they may be useful to you.

They are made entirely with MIT, so what you get is what you see.

The key to the functions are the variables patron_busqueda and patron_encriptado. They are strings of characters that contain the values to encode placed randomly (For example: abcde -> cbdea). It is important that two characters are not repeated. Both variables must have the same size.

I am attaching the .aia so that you can try it and play with it.
Encriptador_ejemplo.aia (5.5 KB)

All the best.

1 Like

Looks good.

Encrypt ? or Encode ?

I think it was a variation of the Caesar cipher... but the truth is that I saw this algorithm a long time ago and I don't remember where.

If you remember which cipher it is, please let us know.

Going through a change history... I think I was supposed to be putting this algorithm into my solution in June 2010... I know it's a bad habit not to write these things down... but I didn't write down where I got this algorithm from.

I have been searching the internet to try and find it, but my search has been fruitless. The only thing I think I remember is that the article or algorithm was written by a woman... whose name I don't remember either. Maybe I'd google my college cryptography professor or whatever class notes I had. The truth is I do not remember him.

If there is any cryptography expert in the room, I would appreciate it if you recognize the algorithm, please tell us which one it is and give us a solution to our question.

Edit: The algorithm has all the earmarks of being an adaptation of Vigènere's algorithm.

Yes, it certainly has similarities, but appears to be an extension or more advanced version of it.

Possibly a keyed Vigenere cipher
Keyed Vigenere Cipher.
This one only uses 26 letters....so could not apply the long keys you used

I am interested in how unbreakable it is. Have found that it is quite good at not repeating the same letters when the same word is used, which is a good thing.

1 Like

Excuse me maybe I write a bestiality but I tried this system and every time I write (hello)
it gives me as result: y876
but he gives me the same letters every time I write hello, so what's the use of this system if anyone can easily trace the result.
It will be enough for those who want to trace the string to use the same system and will understand what a text contains, even if it is 100 pages long.
Maybe I didn't understand how to use it?

Try typing in Hello Hello Hello

You will see it does NOT return y876y876y876

1 Like

OK thank you

Hello.

As @Timai2 says the result depends on the position. If you always write hello, you get the same result, but if you simply include a space in front of it, you'll see that the result is already different.

Sometimes, to mislead what I do is put spaces or some other type of character or mark in front and/or behind so that by changing the size of the text the result is already different.

Good morning everyone.
Yes I understand and I apologize for posting my question inappropriate.

But now I need your help.

Please, in my chat I would like to insert the possibility of encrypting the text when sending and receiving data, decrypting it to insert it in the incoming data visualization listWiev.
I really don't know where to start.

Can you help me?

Please start a new topic for this

Added a code to generate a random pattern.

Encriptador_ejemplo_2.aia (6.7 KB)

These are my blocks for doing the same :slight_smile:

2 Likes

Good morning everyone.
I need to view the encrypted text before sending it to the cloud and view it in reception before it is displayed in the list view of my chat, how can I do it?

This will show the encoded string in a label as it is sent to the chatlist, and also show the latest encoded chat message when any change occurs in the data. Adjust as you wish...

Great thanks. it works great. No that I had any doubts about you. but about me, that I often don't understand even the simplest things.
I still have a problem but about user counts but I'll ask you in the appropriate tab.