|Adding Secure Copy and Secure Shell Clients to uClinux|
This application note explains how to add scp and ssh clients to your uClinux configuration.
Secure copy (scp) and secure shell (ssh) clients are included with the dropbear package. The secure shell client is implemented by a utility called dbclient. The secure copy client is implemented by a utility called scp.
scp actually relies on dbclient to provide a secure connection, so if you need scp, you need ssh (dbclient) also.
To build scp and dbclient, issue the following commands:
[psl@ocean linux-cortexm-x.x.x]$ . ACTIVATE.sh
Make sure the following option is enabled in the dropbear configuration file options.h:
Proceed with the build:
[psl@ocean dropbear]$ make PROGRAMS="dbclient scp dropbear"
Having completed the above commands, you will have the dropbear server as well as the scp and dbclient clients installed in the development tree in the A2F/root/usr/bin directory.
Note that starting from Release 1.10.0 all of dropbear, scp and dbclient are prebuilt and included in the distribution so you don't actually have to build them. If you are a user of Release 1.10.0 or a later release, just read this section as background info and move on to the following section.
Let's use the networking project (projects/networking) as a starting point for adding the scp and ssh clients to the target configuraiton.
networking already has the secure shell server (dropbear) included in the target filesystem. To add scp and ssh, follow the steps below:
Securely copy a file from a host to the target:
~ # scp firstname.lastname@example.org:/etc/issue /
... and backwards:
[psl@pvr ~]$ scp /etc/profile
Login to a host over a secure link:
~ # ssh email@example.com