UNIX 2FA FTP Tutorial

SECSIGN ID PAM FOR TWO-FACTOR AUTHENTICATION


Find out why our Two-Factor Authentication is the best, some key-facts for developers and why you should upgrade to SecSign for your business.

Learn more about the options of on-premise use and your own customized ID App in your corporate design.

Download the plugin as cloud version for a free and convenient protection.


The Pluggable Authentication Modules (PAM) is a software library which offers a general programming interface for authentication services. By using the PAM-API one does no longer need to define the settings for every single authentication application. Instead, individual standarized modules can be used.

The modules can be assigned to individual services in the configuration file. There is no need to change the compilation of the corresponding software. PAM is available for AIX, HP-UX, Solaris, Linux, FreeBSD, NetBSD, Mac OS X and DragonFly BSD.

Table of contents

    Start right now! Questions?

    Feel free to get in touch with us if you need help setting up your SecSign ID plugin or to request a plugin for a not yet supported environment.
    CONTACT US

    1. Installation and Configuration

    Please read the SecSign ID PAM Tutorial before using the SecSign ID PAM for SSH Authentication. Follow steps 3 to 5 to configure and install PAM correctly.

    Note: Using the FTP protocol without additional security measurements results in unencrypted data transfer and is regarded as unsafe. Passwords and other data are transmitted in plain text and can be wiretapped. Using FTP with SSL/TSL generates encrypted data transfer with FTPS and the SecSign ID Two-Factor Authentication acts as additional security measurement.

    Since there are several ways to encrypt FTP connections we use the term FTP in the following tutorial – an encrypted connection is implied, even with the additional protection of the SecSign ID Two-Factor Authentication eliminating the thread of user data compromise.

    We use the common FTP server “ProFTPd” for this tutorial. Other FTP server, for example “vsftpd” support PAM as well and are connected as or similar to the following description.

    Overview on the configuration and installation:

    1. libcurl and gcc are required
    2. inquire SecSignID PAM and unpack
    3. Adjust the path to the configuration file in secsign.c
    4. Add all user names and corresponding SecSign IDs in secsignid.config
    5. make
    6. Copy the compiled file pam_secsignid.so in the PAM library (usually /lib/security)

    2. Configuration with PROFTPD

    Install the ProFTPd as standalone version via apt-get install proftpd openssl. Open the configuration file/etc/proftpd/proftpd.conf and adjust all envirnomental settings for the FTP like data transfer via TLS.

    The ProFTPd configuration script verifies the system’s support for PAM and runs mod_auth_pam automatically.

    With other FTP server (like “vsftpd”) you may have to stare the utilization of PAM manually.

    To grant the user some time to accept the login on his smartphone the values in TimeoutNoTransfer, TimeoutStalled und TimeoutIdle should be extended accordingly, providing at least two minutes.

    Open the configuration file for the ProFTPd PAM settings/etc/pam.d/proftpd and change the following parameter:

    Save the file and reboot the FTP server by employing service proftpd restart.

    In the next step the FTP server can be tested. Please adjust the timeout value in the FTP client program (for example FileZilla) to two minutes to allow the user to accept the session on his smartphone.

    pam_ftp_filezilla_2fa-1

    3. Troubleshooting

    Compilation errors

    The library libcurl needs to be installed in the standard path, otherwise make fails. If libcurl is not on the standard path the compilation needs to be executed manually.

    Authentication errors

    If the authentication fails the debug- and logmodus should be activated (see PAM debug- and logmodus) and the output should be written in a file. This is necessary since PAM normally needs to be silent and does not allow for output for security reasons. If no log- or debug-files are generated the paths provided in secsignid.c are incorrect or no read-and-write authorizations are available.

    A log-file is produced stating all errors. It is determined if libcurl works accurate, if the SecSign ID server is available, if port 443 is available to communicate with the server, if the configuration file is available and if PAM has reading authorization.

    A debug file is created which records the interface communication. It is determined wether errors in the communication persists because no SecSign ID for the specific user was found or if there are errors in a different parameter, for example the service name.

    4. Available APIS

    We provide an ever growing list of APIs and plugins to easily integrate the SecSign ID Two-Factor Authentication in any project. An overview is available at Plugin and APIs.
    We do not only offer APIs in different programming languages but also plugins for CMS, Server and VPN environments, oAuth2 and many more. These plugins use our APIs and offer additional functionalities, for example user management, easy and native installation, logging or integration in firewalls or Active Directory.

    The JIRA plugin for example uses the JAVA-API. The PHP-Api and JS-API is used by WordPress, Joomla, Drupal, Typo3 and many more. The ASP.net/C#-API is used for the Windows and Cisco VPN and the C-API is used for protecting Unix SSH services. The Objective-C API is used by our AppleTV and iPhone/iPad apps.

    available_apis

    5. See for yourself

    You can experience the SecSign ID two-factor authentication and the two-factor login by simply integrating the plugin into your website or test environment. Or you can try out the login process on our website without having to register first. You already have a SecSign ID or you want one? Login now and use the portal or use our hassle free registration.

    See for yourself how fast and convenient the login process using challenge-response authentication with 2048-bit key pairs is. There is no need for passwords, and no passwords or other confidential information are ever transmitted. It is easy to integrate and simple to use.

    For more information about the patented SafeKey procedure and it's unique security can be found here.

    If you are missing an API for the programming language you are working with, feel free to contact us and we’ll find a solution with you. If you need help with the integration into an existing system or you can’t find the plugin for your content management system you are working with, don’t hesitate to contact our support team.

    Your own ID-Server

    On premise installations of SecSign ID offer the flexibility to connect with your preferred servers, services, and devices. And you can customize the SecSign ID with your own organization’s branding.

    your_own_id

    Why upgrade to SecSign?

    On-premise or in the cloud

    Choose between our SecSign ID Cloud or operate your own on-premise Two-Factor Authentication server.

    Easy customization

    Operate your own YourBrand ID app - Two-Factor Authentication customized to your needs.

    Ready-to-use SDK

    Integrate SecSign ID Two-Factor Authentication in existing apps with our ready-to-use SDK.

    Easy user management

    Use the Two-Factor Authentication Server to secure your company Active Directory/LDAP. Your own Identity and Access Management System, for example for mandatory updates and additional security features.

    Cover all logins

    Integration in any login environment: web, local, VPN, remote desktop, mobile logins and many more.

    Plugins for all your needs

    No need for complex integration: we have plugins for almost all environments.

    Do NOT follow this link or you will be banned from the site!