views:

88

answers:

2

hey all,

is it possible to have some sort of very simple reversible encryption in php that can be reversed using C# Winforms?

thank you

+2  A: 

Yes. Algorithms are not language specific.

siride
+1  A: 

Sure. In the PHP part you can use the bitwise operator ^, but you'll first have to convert the string into an array of integers (e.g. array_map('ord', str_split($str))) and then do an inner product with the one-time pad, xor taking the role of multiplication and concatenation taking the role of addition.

Remember that if you re-use the pad, the security of the encryption falls apart.

Artefacto