Skip to content

-p/--prompt behaviour breaks ansible #1461

@EvoRowan

Description

@EvoRowan

-p on C sudo would replace the entire prompt which ansible relied on for privilege escalation. -p on sudo-rs just appends it within the brackets. With sudo-rs being the default on Ubuntu now, this breaks a lot of ansible scripts.

To Reproduce
$ sudo -p "password:" hostname
[sudo: password:] Password:

Expected behavior
$ sudo -p "password:" hostname
password:

Environment:

  • Linux distribution: [Ubuntu 25.10]
  • sudo-rs version [0.2.8`]

Additional context
Same behavior happens on 0.2.12 as well

Metadata

Metadata

Assignees

No one assigned

    Labels

    C-pamPAM libraryenhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions