Re: [Fed-Talk] How to have SSH listen to two ports on Leopard
Re: [Fed-Talk] How to have SSH listen to two ports on Leopard
- Subject: Re: [Fed-Talk] How to have SSH listen to two ports on Leopard
- From: Todd Heberlein <email@hidden>
- Date: Tue, 30 Oct 2007 21:31:21 -0700
Hi Carib,
I did the following:
(1) copied the ssh.plist file in the /System/Library/LaunchDaemons
directory (I called the new one ssh2.plist).
(2) Modified the Label's string to give it a different name. I used
the following value:
<string>com.openssh.sshd2</string>
(3) Modified the listening port to whatever I want (I used port 2222)
<string>2222</string>
(4) Then I rebooted my machine (I'm sure I could have used launchctl,
but this was easy).
(5) From a remote machine I logged in
ssh -p 2222 email@hidden
or
ssh email@hidden
Below is the actual launchd ssh2.plist file that I used.
Todd
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://
www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>Label</key>
<string>com.openssh.sshd2</string>
<key>Program</key>
<string>/usr/libexec/sshd-keygen-wrapper</string>
<key>ProgramArguments</key>
<array>
<string>/usr/sbin/sshd</string>
<string>-i</string>
</array>
<key>SHAuthorizationRight</key>
<string>system.preferences</string>
<key>SessionCreate</key>
<true/>
<key>Sockets</key>
<dict>
<key>Listeners</key>
<dict>
<key>Bonjour</key>
<array>
<string>ssh</string>
<string>sftp-ssh</string>
</array>
<key>SockServiceName</key>
<string>2222</string>
</dict>
</dict>
<key>StandardErrorPath</key>
<string>/dev/null</string>
<key>inetdCompatibility</key>
<dict>
<key>Wait</key>
<false/>
</dict>
</dict>
</plist>
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Fed-talk mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden