- 01
- 02
- 03
- 04
- 05
- 06
- 07
- 08
- 09
- 10
- 11
- 12
- 13
- 14
- 15
- 16
- 17
- 18
- 19
- 20
- 21
- 22
- 23
- 24
- 25
- 26
- 27
- 28
- 29
- 30
/// <summary>
/// Проверка пароля *
/// </summary>
private string CheckPassword(String _password)
{
int kol = 0;
const int LEN = 32;
if (_password.Length == LEN)
return _password;
else
{
StringBuilder _pass = new StringBuilder(_password, LEN);
if (_password.Length > LEN)
{
kol = _password.Length - LEN;
return (_password.Substring(0, _password.Length - kol));
}
else
{
kol = LEN - _password.Length;
int i = 0;
while (i != kol)
{
_pass.Append(" ");
i++;
}
}
return _pass.ToString();
}
}