Update program.cs to avoid index out of bounds

This commit is contained in:
Zontreck 2019-12-21 03:52:43 -07:00
parent bb3a43bebb
commit 21a5eb714a

View file

@ -796,6 +796,10 @@ namespace Bot
public void CalculateKey(string K)
{
string valid = "abcdefghijklmnopqrstuvwxyz1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ=.+/\\";
while(valid.Length < K.Length)
{
valid += valid;
}
StringBuilder tmp = new StringBuilder(_key);
for (int i = 0; i < _key.Length; i++)