ssh/terminal: add GetState and make ReadPassword work in raw mode.
ssh/terminal: add GetState and make ReadPassword work in raw mode.

GetState is useful for restoring the terminal in a signal handler.

R=golang-dev, rsc
CC=golang-dev
https://codereview.appspot.com/6990043

dizzyd/go.crypto,polydawn-ports/go.crypto,tonnerre/golang-go.crypto,drhax9908/go.crypto,cmars/sshlurp-go.crypto,cmars/sshlurp-go.crypto,cmars/go.crypto,dizzyd/go.crypto,isislovecruft/go.crypto,cmars/go.crypto,xman1101/terminal,tonnerre/golang-go.crypto,polydawn-ports/go.crypto,isislovecruft/go.crypto,xman1101/terminal,drhax9908/go.crypto