Authenticating users against your own DataBase

Syncplify.me Server! version: 4.0.16+

Note: in order to use the code posted in this article you need to be running at least version 4.0.16 or greater of Syncplify.me Server!

As you all know, Syncplify.me Server! already supports its own internal users, as well as Windows and Active Directory users (and groups, depending on the license type). Yet, some of our customers need to implement totally custom authentication methods, often based on their own user databases.

In this article we will show one way to do so. This is clearly just meant to serve as an example, and real-life scenarios require some further customization to the DB and the script posted here. But it’s a fairly decent starting point.

So, the background scenario for this example is:

  • our users’ authentication data are stored in a Microsoft(R) Access database
  • in our DB, each user is associated to a “category” (in this case his/her department: sales, marketing, …)
  • for the sake of this example, all users’ passwords are set to “password” (without quotes)
  • the script is pretty sophisticated, because besides authenticating the user, it will load a user profile that belongs to the “category” of the user from the main Syncplify.me Server! user-base

So let’s start taking a look at our user database: Continue reading

Scripting lesson: using scripting and session info

Syncplify.me Server! version: 4.0.13+

This articles shows how to use scripting, event-handling and session information from within Syncplify.me Server! For the sake of this example we will only log such information in the log file, but in real-life production scenarios you can use these info as you wish (for example you may want to send them via email to someone, or even make decisions based upon them).

Let’s start by preparing the script that – as we said – will log some info in your Syncplify.me Server!’s log file:

We save the above script with the following name/description: “Log several client and connection info”.

Then we add an event-handler to trigger the execution of the script. Since the script contain references to file-transfer-related variables (VirtualObjectName and ObjectName) it seems obvious to trigger its execution upon occurrence of a file-transfer-related event. For the sake of this example we have chosen the AfterFileUpload event, which occurs every time a file is successfully uploaded by a client onto the server. Continue reading

Extending your SFTP Server: Lesson #1

This is the first of a series of video lessons to help our users learn how to unleash the full power of Syncplify.me Server! by writing scripts that are executed automatically upon occurrence of certain events.

This first script is kind of a “hello world”, but it’s meant to give our users a glimpse of the features Syncplify.me Server! puts at their disposal.

Once you’ve watched the video, if you don’t want to re-type the script by hand, here’s the source code for you, ready to copy and paste.

 

Handling custom SITE commands over FTP(E/S)

This article refers to a new feature that will be introduced in the upcoming Syncplify.me Server! version 4.0.

As many of you know, the FTP protocol (and therefore also both its encrypted versions FTPS and FTPES) feature a very simple way for clients to send custom commands to the server: the SITE command (RFC 959).

Some servers implement a fixed set of site-specific commands through it, but Syncplify.me Server! v4 goes beyond that and gives the server’s administrator total control over the SITE command handler behavior and response. Continue reading

Syncplify.me Server! v3.0: improved session object

Thanks to our precious beta-testers (Izzy, Antonio, and “the gang”) we have been greatly improving our session object, for the joy of all users who take advantage of Syncplify.me Server!’s event-handling subsystem in order to run their own scripts.

In addition to all the properties and methods that were already present in v2.x, the new version will also feature the following ones:

Continue reading