Skip to content

Shell tool cannot handle interactive stdin input on macOS (kinit, ssh-add, etc.) #8992

Description

@iiwaasnet

Before opening, please confirm:

  • I have searched for duplicate or closed issues

Operating System

macOS 26.5 (Tahoe)

Kiro Version

kiro-cli 2.5.0

Bug Description

The shell tool does not provide stdin to commands that require interactive password input. This affects any command that reads credentials from the terminal — not just sudo, but also kinit, ssh-add, security unlock-keychain, etc.

When such a command is executed via the shell tool, it either:

  • Hangs waiting for input that never arrives
  • Fails silently because stdin is not connected to a TTY

This makes it impossible for the AI agent to run any command requiring user authentication.

Steps to Reproduce

  1. Start kiro-cli chat
  2. Ask the agent to run: kinit user@REALM (or any command requiring password input)
  3. The command hangs or fails — there is no way to provide the password

Expected Behavior

Either:

  • The shell tool should provide a mechanism to pass stdin input to interactive commands
  • Or clearly detect and report that a command requires interactive input, so the user can run it manually

Additional Context

  • Related Linux issue: sudo password prompt unusable in kiro-cli chat on Ubuntu 26.04 #7997 (sudo password prompt unusable on Ubuntu)
  • The Linux issue has a partial fix being worked on in sudo-rs (trifectatechfoundation/sudo-rs#1591, #1592), but that only addresses sudo's TTY detection
  • On macOS the problem is broader — it's not a sudo-rs issue, it's that kiro-cli's shell tool doesn't connect stdin to the user's terminal at all
  • Affects: kinit, ssh-add, security unlock-keychain, sudo, and any other command reading passwords from /dev/tty or stdin

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions