mirror of
https://github.com/raphaeIl/Novaria.git
synced 2025-12-14 15:34:37 +01:00
serverlist handler + basic crypto, rename project
This commit is contained in:
14
Novaria.Common/Crypto/XOR.cs
Normal file
14
Novaria.Common/Crypto/XOR.cs
Normal file
@@ -0,0 +1,14 @@
|
||||
namespace Novaria.Common.Crypto
|
||||
{
|
||||
public static class XOR
|
||||
{
|
||||
public static void Crypt(byte[] bytes, byte[] key, uint offset = 0)
|
||||
{
|
||||
while (offset < bytes.Length)
|
||||
{
|
||||
bytes[offset] ^= key[offset % key.Length];
|
||||
offset++;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user