Search code examples
bashsshexpectsudosu

Does the expect command work after an su is executed in the script?


Does the expect command work after an su is executed in the script?

Does expect work by emulating the feeding of key strokes to the terminal?


Solution

  • Yes and yes, although the second bit ("emulating ... key strokes") is an oversimplification.