- Ensure that IBM® WebSphere® Partner Gateway Advanced (or Enterprise) Edition V6.2 with Fix Pack 2 or later has been installed and configured on Windows.
- Download the latest version of freeSSHd.
- Download the latest version of PuttyGen.
After you have downloaded freeSSHd, complete the following steps to install it:
- Start the freeSSHd installer: Double-click on freeSSHd.exe.
- When the "Welcome to the freeSSHd SSH/Telnet Server Setup Wizard" dialog is displayed, click Next.
- When the "Select Destination Location" dialog is displayed, change the installation location to C:\freeSSHd and click Next.
- When the "Select Components" dialog is displayed, ensure that Full Installation is selected and click Next.
- When the "Select Start Menu Folder" dialog is displayed, click Next.
- When the "Select Additional Tasks" dialog is displayed, click Next.
- When the "Ready to Install" dialog is displayed, click Next.
- When the "Try Other WeOnlyDo.com Products" dialog is displayed, click Close.
- When the "Private keys should be created. Should I do it now?" dialog is displayed, click Yes.
- When the "Do you want to run FreeSSHd as a system service?" dialog is displayed, click No.
- When the "Completing the freeSSHd SSH/Telnet Server Setup Wizard" dialog is displayed, click Finish.
PuttyGen is downloaded from the Web site in binary form and does not require installation -- simply copy it to the WebSphere Partner Gateway machine.
Creating the FTP directory structure
Follow the steps below to create the directory structure required for this article:
- Create a new c:\ftproot folder
- Create a new c:\ftproot\fromWPG folder to be used by the WebSphere Partner Gateway Destination
- Create a new c:\ftproot\toWPG folder to be polled by the WebSphere Partner Gateway Receiver
Creating the public and private keys
Here are the steps to create the openSSH format public and private keys using PuttyGen:
- Start PuttyGen.
- When the Putty Key Generator screen appears, click Generate to begin generating the new public/private key pair:
Generate new public/private key pair

- Move the mouse around the highlighted area until the progress bar is full to generate the key:
Create a passphrase

- Once the public/private key pair has been generated, enter a passphrase such as passw0rd:
Generate new public/private key pair

- Select the entire contents of the public key to paste into the OpenSSH authorized_keys file box, then right-click and select Copy:
Select the public key

- Open a new document in Notepad and paste the public key into it. The key should be on a single line and start with ssh-rsa:
New Notepad document

- Save the public key to a file that has the same name as the user (userkey) that is configured in freeSSHd (it will be created below) with no extension in the freeSSHd installation directory.
In this case, save the file as c:\freesshd\userkey (you may have to manually rename the file to remove the extension):
Save the public key

- Save the private key in the OpenSSH format: Select Conversions => Export OpenSSH key from the PuttyGen menu bar:
Export the private key

- Save the file as c:\userkeyprivate:
Save the private key

- Close PuttyGen.
This section shows you how to configure the freeSSHd server and create two new users:
- Start freeSSHd using the Windows Start menu: Select Programs => freeSSHd => freeSSHd.
- When the "Thank you for using freeSSHd" dialog is displayed, click OK.
- Double-click on the freeSSHd icon on the Task bar to start the freeSSHd Settings application:
Open freeSSHd settings

- When the freeSSHd Settings application is displayed, click on the Authentication tab.
- Validate the following fields:
Public key folder C:\freeSSHd\ Password authentication Allowed Public key authentication Allowed - If any changes were made, click Apply.
- Click on the SFTP tab.
- Change the SFTP home path to C:\ftproot and click Apply.
- Click on the Users tab.
- Click Add and enter the following values:
Login userhash Authorization Password stored as SHA1 hash Password passw0rd Password (again) passw0rd User can use SFTP
userhash User Settings

- Click OK.
- When you are returned to the Users tab, click Add and enter the following values:
Login userkey Authorization Public key (SSH only) User can use SFTP - Click OK.
- When you are returned to the Users tab, click Apply.
- Click on the Logging tab.
- Select Log Events and click Apply.
- Click OK to exit the freeSSHd Settings application.
- Stop freeSSHd: right-click on the freeSSHd icon on the Task bar and select Unload.
- Start freeSSHd using the Windows Start menu: Select Programs => freeSSHd => freeSSHd.
- Double-click on the freeSSHd icon on the task bar to start the freeSSHd Settings application.
- Validate that the configuration changes you made to the Authentication, SFTP, Users, and Logging tabs have been persisted.
Creating a WebSphere Partner Gateway receiver (password)
This section shows you how to configure the WebSphere Partner Gateway SFTP receiver for a user that is authenticated using a password (hash):
- Create a new receiver: Select Hub Admin => Receivers => Create.
- Enter a receiver name (SFTP).
- Select SFTP from the Transport Type drop-down.
- Enter the following values:
Operation Mode Production SFTP Host IP / Host Name 127.0.0.1 Port Number 22 Remote Event Directory /toWPG Authentication Type User Name / Password User Id userhas Password passw0rd
SFTP receiver configuration

- Click Save.
- Before using this receiver, restart the WebSphere Application Server that hosts the WebSphere Partner Gateway receiver application.
- After the WebSphere Partner Gateway receiver has been restarted, this SFTP receiver will be ready to receive files from the SFTP server.
Creating a WebSphere Partner Gateway destination (private key)
This section shows you how to configure the WebSphere Partner Gateway SFTP destination for a user that is authenticated using a private key:
- Create a new destination for an external partner.
- Enter a destination name (SFTP)
- Select SFTP from the Transport Type drop-down.
- Enter the following values:
SFTP Host IP / Host Name 127.0.0.1 Port Number 22 Remote Event Directory /fromWPG Authentication Type Private Key Private Key File c:/userkeyprivate Pass Phrase passw0rd
SFTP destination configuration

- Click Save.
- Before using this destination, update the connection and restart the WebSphere Application Server that hosts the WebSphere Partner Gateway Document Manager application.
- Once the WebSphere Partner Gateway Document Manager has been restarted, this SFTP destination is ready for testing.
| Description | Name | Size | Download method |
|---|---|---|---|
| Code sample | SFTPwithWPG.zip | 687 KB | HTTP |
Information about download methods
- WebSphere Partner Gateway product page
Product descriptions, product news, training information, support information, and more. - WebSphere Partner Gateway information center
A single Web portal to all WebSphere Partner Gateway documentation, with conceptual, task, and reference information on installing, configuring, and using WebSphere Partner Gateway. - WebSphere Partner Gateway requirements
Hardware and software requirements for different versions of WebSphere Partner Gateway. - WebSphere Partner Gateway support
A searchable database of support problems and their solutions, plus downloads, fixes, problem tracking, and more. - WebSphere Partner Gateway FAQs
Answers to frequently asked questions about licensing, support, migration, and technical issues. - B2B innovation with WebSphere Partner Gateway leveraging SOA and BPM
This IBM white paper shows you how WebSphere Partner Gateway provides innovative ways for you to connect to Business Partners within an SOA - developerWorks WebSphere developer resources
Technical information and resources for developers who use WebSphere products. developerWorks WebSphere provides product downloads, how-to information, support resources, and a free technical library of more than 2000 technical articles, tutorials, best practices, IBM Redbooks, and online product manuals. - developerWorks WebSphere application connectivity developer resources
How-to articles, downloads, tutorials, education, product info, and other resources to help you build WebSphere application connectivity and business integration solutions. - Most popular WebSphere trial downloads
No-charge trial downloads for key WebSphere products. - WebSphere forums
Product-specific forums where you can get answers to your technical questions and share your expertise with other WebSphere users. - WebSphere on-demand demos
Download, watch, and learn what WebSphere products and WebSphere-related technologies can do for your company. - developerWorks WebSphere weekly newsletter
The developerWorks newsletter gives you the latest articles and information only on those topics that interest you. In addition to WebSphere, you can select from Java, Linux, Open source, Rational, SOA, Web services, and other topics. Subscribe now and design your custom mailing. - WebSphere-related books from IBM Press
Convenient online ordering through Barnes & Noble. - WebSphere-related events
Conferences, trade shows, Webcasts, and other events around the world of interest to WebSphere developers. - developerWorks blogs
Join a conversation with developerWorks users and authors, and IBM editors and developers. - developerWorks Webcasts
Free technical sessions by IBM experts that can accelerate your learning curve and help you succeed in your most difficult software projects. Sessions range from one-hour Webcasts to half-day and full-day live sessions in cities worldwide. - developerWorks podcasts
Listen to interesting and offbeat interviews and discussions with software innovators. - developerWorks on Twitter
Check out recent Twitter messages and URLs.
Dave Mulley is an IT Specialist and a member of the IBM Software Services for WebSphere Enablement team based in Raleigh, North Carolina. Dave is focused on the WebSphere Business Integration family of products and has worked for IBM since 1999. You can reach Dave at dmulley@us.ibm.com



