Merge pull request #505 from Dliv3/master

Fix winrm login failed
main
mpgn 2021-12-17 21:42:55 +01:00 committed by GitHub
commit 202ae8797b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -135,7 +135,7 @@ class winrm(connection):
log.addFilter(SuppressFilter()) log.addFilter(SuppressFilter())
self.conn = Client(self.host, self.conn = Client(self.host,
auth='ntlm', auth='ntlm',
username=username, username=u'{}\\{}'.format(domain, username),
password=password, password=password,
ssl=False) ssl=False)
@ -182,7 +182,7 @@ class winrm(connection):
if nthash: self.nthash = nthash if nthash: self.nthash = nthash
self.conn = Client(self.host, self.conn = Client(self.host,
auth='ntlm', auth='ntlm',
username=username, username=u'{}\\{}'.format(domain, username),
password=ntlm_hash, password=ntlm_hash,
ssl=False) ssl=False)