Skip to content

Commit 12b4f6d

Browse files
authored
Update README.md
1 parent 2a6a80d commit 12b4f6d

File tree

1 file changed

+18
-7
lines changed

1 file changed

+18
-7
lines changed

README.md

Lines changed: 18 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
1-
# touch2sudo
21
<p align="center">
32
<img src="https://github.com/prbinu/touch2sudo/raw/master/images/t2s-2.png">
43
</p>
54

5+
# touch2sudo
6+
67
<p align="center">
78
<img src="https://github.com/prbinu/touch2sudo/raw/master/images/t2s-1.png">
89
</p>
@@ -37,7 +38,9 @@ git clone https://github.com/prbinu/touch2sudo
3738

3839
3. Archive: (*Product -> Archive -> Distribute Content -> Build Products -> Next -> Save*) Save the archive folder. The touch2sudo executable will be in the `<ArchiveDir>/Product/usr/local/bin` path.
3940

40-
4. Copy `touch2sudo` binary to `/usr/local/bin`
41+
4. Install: Copy `touch2sudo` binary to `/usr/local/bin`
42+
43+
5. Run: `touch2sudo`
4144

4245

4346
## Configure ssh-agent with touch2sudo
@@ -73,16 +76,24 @@ Start `ssh-agent`
7376
$ export SSH_ASKPASS=/usr/local/bin/touch2sudo
7477
$ export DISPLAY=0
7578
$ eval $(ssh-agent)
76-
Agent pid 56587
79+
Agent pid 51863
80+
81+
$ ssh-add -L
82+
The agent has no identities.
83+
84+
$ env | grep SSH
85+
SSH_AGENT_PID=51863
86+
SSH_AUTH_SOCK=/var/folders/hm/x1_38yz53td1jty5xgs39dxm2lm58d/T//ssh-JssXsflTuHrC/agent.51862
87+
SSH_ASKPASS=/usr/local/bin/touch2sudo
7788
78-
$ ssh-add -c ~/.ssh/id_rsa_sudo
79-
Identity added: /Users/binu/.ssh/id_rsa_sudo (binu@localhost)
89+
$ ssh-add -c id_rsa_sudo
90+
Identity added: id_rsa_sudo (binu[email protected])
8091
The user must confirm each use of the key
8192
```
8293

8394
To make it work, on remote server you need to configure `pam-ssh-agent-auth` - a PAM module that does SSH key authentication for sudo.
8495
pam-ssh-agent-auth is based on SSH *agent-forwarding* feature that allow the PAM module to authenticate sudo command using key cached in ssh-agent running on your workstation (Mac).
8596

86-
For the complete information on end to end setup, please read: <TODO>
97+
For the complete information on end to end setup, refer:
98+
https://medium.com/@prbinu/touch2sudo-enable-remote-sudo-two-factor-authentication-using-mac-touch-id-df638b7da594
8799

88-
>

0 commit comments

Comments
 (0)