示例#1
0
 /// <summary>
 /// Create a new pserver authentication object.  Populate the cvsroot, username
 ///     and password variables that will be sent to the server.  When the password
 ///     is populated it is encrypted with the password scrambler.
 /// </summary>
 /// <param name="cvsroot">A cvsroot line that locates the repository and
 ///     the server.</param>
 /// <param name="userName">The name of the user that is logging in.</param>
 /// <param name="password">A password for the user.</param>
 public PServerAuthRequest(string cvsroot, string userName, string password)
 {
     this.cvsroot  = cvsroot;
     this.userName = userName;
     this.password = password;
     this.password = PasswordScrambler.Scramble(this.password);
 }
示例#2
0
 protected override void LoadState()
 {
     scrambler = new(ParsedFileLines(Operation.ParseOperation));
 }
示例#3
0
 protected override void ResetState()
 {
     scrambler = null;
 }
 /// <summary>
 /// Lookup the password for the given file
 /// </summary>
 /// <returns></returns>
 private string GetPassword () {
     Manager manager = new Manager(this.Repository.LocalDirectory);
     return PasswordScrambler.Descramble(manager.ReadPassword(this.CvsRoot));
 }