Example #1
0
 public PasswordProvider(IMsMcsAdmPwdProvider msMcsAdmPwdProvider, ILithnetAdminPasswordProvider lithnetProvider, IEncryptionProvider encryptionProvider, ICertificateProvider certificateProvider)
 {
     this.msLapsProvider      = msMcsAdmPwdProvider;
     this.lithnetProvider     = lithnetProvider;
     this.encryptionProvider  = encryptionProvider;
     this.certificateProvider = certificateProvider;
 }
 public LapsAgent(ILogger <LapsAgent> logger, IDirectory directory, ILapsSettings settings, IPasswordGenerator passwordGenerator, IEncryptionProvider encryptionProvider, ICertificateProvider certificateProvider, ILocalSam sam, ILithnetAdminPasswordProvider lithnetAdminPasswordProvider, IMsMcsAdmPwdProvider msMcsAdmPwdProvider)
 {
     this.logger              = logger;
     this.directory           = directory;
     this.settings            = settings;
     this.passwordGenerator   = passwordGenerator;
     this.encryptionProvider  = encryptionProvider;
     this.certificateProvider = certificateProvider;
     this.sam = sam;
     this.lithnetAdminPasswordProvider = lithnetAdminPasswordProvider;
     this.msMcsAdmPwdProvider          = msMcsAdmPwdProvider;
 }
 private LapsAgent BuildAgent(ILapsSettings settings = null, IDirectory directory = null, IPasswordGenerator passwordGenerator = null, IMsMcsAdmPwdProvider admPwdProvider = null, ILocalSam sam = null, IEncryptionProvider encryptionProvider = null, ICertificateProvider certificateProvider = null, ILithnetAdminPasswordProvider lithnetProvider = null)
 {
     return(new LapsAgent(
                Mock.Of <ILogger <LapsAgent> >(),
                directory ?? this.directory.Object,
                settings ?? this.settings.Object,
                passwordGenerator ?? this.passwordGenerator.Object,
                encryptionProvider ?? this.encryptionProvider.Object,
                certificateProvider ?? this.certificateResolver.Object,
                sam ?? this.sam.Object,
                lithnetProvider ?? this.lithnetPwdProvider.Object,
                admPwdProvider ?? this.admPwdProvider.Object));;
 }