- 512 名前:デフォルトの名無しさん mailto:sage [2009/08/14(金) 11:45:44 ]
- byteを簡単に暗号と復号しようと思ったのですが復号できません。
どうして復号できないのかきっと間抜けな漏れに教えてください。 public byte[] ByteXor(byte[] dat, byte[] account, byte[] password) { int len_data = dat.Length; int len_account = account.Length; int len_password = password.Length; for (int i = 0; len_data > i; i++) { int ap = i % len_account; int pp = account[ap] % len_password; dat[i] = (byte)(dat[i] ^ password[pp]); } return dat; }
|

|