2.1. Managing credentials: username/password authentication

For username/password authentication, you need create and configure a password file for mdtmFTP server.

2.1.1. On the server side

On each host that runs mdtmFTP server, create a password file by using globus password tools, such as globus-gridftp-password-nostdin, which are available in /usr/local/mdtmftp/1.1.1/sbin/ in the mdtmftp:1.1.1-xenial docker image.

For example, assuming user account mdtmftp has been added in container and in host, you can run the following commands to create a password file /home/mdtmwork/passfile, and to assign password 123456 to mdtmftp:

$ mkdir -p /home/mdtmwork && cd /home/mdtmwork
$ touch passfile
$ docker run \
         -u mdtmftp \
         -v `pwd`:/mdtmwork \
         publicregistry.fnal.gov/bigdata_express/mdtmftp:1.1.1-xenial \
         /usr/local/mdtmftp/1.1.1/sbin/globus-gridftp-password-nostdin >> passfile 123456

A line like below will be added in /home/mdtmwork/passfile:

mdtmftp:c1CvYmpprfOpc:4001:4001::/home/mdtmftp:/bin/bash

Repeat the docker command if you need to set up passwords for other users.

2.1.2. On the client side

Assume that a user mdtmftp with password 123456 has been configured on the server side. To submit a data transfer job using this username and password, run mdtmFTP client like:

$ sudo docker run \
              -ti --rm \
              --net=host \
              -v `pwd`:/mdtmwork \
              publicregistry.fnal.gov/bigdata_express/mdtmftp:1.1.1-xenial \
              /usr/local/mdtmftp/1.1.1/bin/mdtm-ftp-client \
              -vb -p 4 ftp://mdtmftp:123456@bde1.fnal.gov:5050/data1/linux-4.13.4/ file:///tmp/

More example are in Authentication method: username/password.