|
FileZilla Server: Plugin Design | Basic Configuration | Implicit SSL part 1 | Implicit SSL part 2 | Portable FileZilla FTPd | Download and support |
| Uniform Server 3.5-Apollo FileZilla Server. |
Uniform Server and portable FileZilla Server
The previous pages covered a general portable version of the FileZilla Server strictly speaking not truly portable because of absolute paths used on a host machine.
This page looks at final tweaks required to make the server truly portable. My definition of portability the FTP server shall shadow Uniform Server, and have the capability of transferring data to any folder within the web-root folder www.
The FTP server requires reconfiguring to run on the virtual drive created by Uniform Server. All that is required is to re-map the location of the server certificate and to set the home folder to server root folder www.
Note: The path must be the virtual drive.
This updates the configuration file \Uniform Server\udrive\filezilla_server\FileZilla Server.xml
Open this file and you will find these three lines:
<Item name="SSL Key file" type="string">w:\filezilla_server\certificate.crt</Item> <Item name="SSL Certificate file" type="string">w:\filezilla_server\certificate.crt</Item> <Permission Dir="w:\www">
These three lines prevent the server being portable should a user start Uniform Server with a different drive letter the FTP server will fail.
The solution is to run a small script that changes the drive letter when Uniform Server is run. The variable %Drive% (in Server_Start.bat) contains a users selected drive. This is passed to a Perl script that replaces the old drive letter with the new one.
I always use a batch file to hammer a peg in the ground (defines the current working directory and saves return path to caller) from this reference run the Perl script.
Create the following two files and save in folder \Uniform Server\udrive\filezilla_server:
pushd %~dp0 ..\usr\bin\perl change_drive.pl %1 popd
First line save return path and sets working directory to current folder.
Execute Perl interpreter (relative to current folder) pass it the script name and drive letter %1 passed to this batch file.
Reinstate the return-path and return to calling program (Server_Start.bat)
#--- Get parameter passed to this script
my $new_drive_letter = $ARGV[0];
#--- Read file to array
open FILE,"<FileZilla Server.xml" or die $!;
@lines=<FILE>;
close (FILE);
#--- Search for *:\ and replace with $new_drive_letter:\
foreach (@lines) {
$_ =~ s/.:\\/$new_drive_letter:\\/g;
}
#--- Write array to file
open FILE,">FileZilla Server.xml" or die $!;
print FILE @lines;
close (FILE);
exit;
With so many different start and stop files the folder Uniform Server quickly becomes cluttered hence I tend to delete all unused files. To reduce these further there is no need to have separate start and stop files for FileZilla server they can be integrated with Uniform Server’s batch files.
To avoid confusion the download will add two new files named New_server_start.bat and New_stop.bat either modify the originals as shown below or delete the originals and rename the the new files Server_Start.bat and Stop.bat respectively. File filezilla_admin.bat remains to provide independent control of the interface.
Modification to New_server_start.bat requires the addition of two lines as shown:
set closeit=%programit%close.bat %Disk% :### New for FileZilla Server ################################## CALL udrive\filezilla_server\change_drive_letter.bat %Disk% CALL udrive\filezilla_server\filezilla_start.bat :############################################################### %Disk%:
Modification to New_stop.bat requires the addition of a single line as shown:
@echo off :### New for FileZilla Server################## CALL udrive\filezilla_server\filezilla_stop.bat :############################################## udrive\home\admin\program\pskill.exe Apache.exe c
This file remains unchanged shown for completeness:
udrive\filezilla_server\filezilla_admin.bat
That completes the portable plugin, all that remains is to test it.
You have three options either use your preferred client or use FireFTP covered on this page or use the Fillzila Client.
If you are not already running the FileZilla client why not download FileZilla Portable from PortableApps.com it complements our portable FileZilla server.
|
After downloading there is no configuration it works straight out of the box. Run FileZilla client. In the Qickconnect boxes type:
An Unknown certificate pop-up is displayed. I do know this, Note 1: Note the detail provided in the certificate. Unit: Is pertinent DO create a new certificate. Note 2: Take another look at the Quickconnect bar! In particular Host: and Port: | |
Download the following file filezilla_server_plugin.exe from the Download and support page. Save it to folder Uniform Server.
Double click to extract the files no need to change the path. Once extracted if you wish to save space, delete file filezilla_server_plugin.exe
The projected just covered started life when I required a secure FTP sever to run on a wireless network, installation method and program was of little importance. I tried FileZilla FTPd and discovered it served the purpose admirably. After looking at several files discovered it was inherently portable.
I could not resist the temptation to convert it into a portable version for Uniform Server. FileZilla FTPd like SlimFTPd is easy to use however it has one significant advantage, built in encryption and automatic certificate generation. This alone gave the inspiration to produce a working plugin. To a certain extent achieved my goal however it does not work straight out of the box, minor modifications are required.
Although operation over the Internet was not a requirement I decided to tackle this and provide detailed information and a default configuration that would serve as a starting point.
The plugin may require a few refinements but essentially it is a working design. Portable FileZilla FTPd plugin along with the FileZilla client make an excellent solution for transferring secure FTP data.
| | Ric |