Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions sssd_test_framework/utils/sssctl.py
Original file line number Diff line number Diff line change
Expand Up @@ -245,7 +245,9 @@ def umockdev_passkey_register(

return result.stdout_lines[-1].strip()

def user_checks(self, username: str, action: str = "acct", service: str = "system-auth") -> ProcessResult:
def user_checks(
self, username: str, action: str = "acct", service: str = "system-auth", auth_input: str | None = None
) -> ProcessResult:
"""
Print information about a user and check authentication

Expand All @@ -255,10 +257,12 @@ def user_checks(self, username: str, action: str = "acct", service: str = "syste
:type action: str
:param service: PAM service, defaults to "system-auth"
:type service: str
:param auth_input: input during authentication (action "auth"), e.g. password or pin
:type auth_input: str | None, optional
:return: Result of called command
:rtype: ProcessResult
"""
return self.host.conn.exec(["sssctl", "user-checks", username, "-a", action, "-s", service])
return self.host.conn.exec(["sssctl", "user-checks", username, "-a", action, "-s", service], input=auth_input)

def user_show(self, user: str | None = None, sid: str | None = None, uid: int | None = None) -> ProcessResult:
"""
Expand Down
Loading