Important Security Notes
Firefly QSL is meant to face the public internet. Anyone can search for QSOs and draw cards. Only someone with the club callsign and password can load logs, export the log, or change the card.
Use HTTPS
Configure the web server to redirect plain http:// requests to
https://. When a page is served over HTTPS, Firefly QSL marks the login
cookie Secure and sends an HSTS header so browsers keep using HTTPS.
Without HTTPS the club password crosses the network in clear text every time someone logs in.
The Password
The password is the only protection on the log loader. Firefly QSL works on a semi-trust basis: anyone who has the password can load QSOs under any callsign, so a weak or widely shared password lets someone load bogus QSOs or fill the database.
- Logins are refused while
$club_passwordis still the shipped default. - Rather than storing the password itself, set
$club_password_hash. See Configuration. - Keep the password in
config.local.phpso it stays out of git and survives upgrades. See Configuration.
Limits Built Into the Application
| What | Limit |
|---|---|
| Failed logins | After 10 failures from one address, that address must wait 15 minutes |
| Idle login | A login ends after 2 hours without activity |
| Card drawing | 30 cards per address every 10 minutes |
Rate limits are kept per client IP address in small files in the system
temp directory (fireflyqsl-ratelimit). They need no database table or
extra PHP extension.
Behind a reverse proxy
Behind a reverse proxy every visitor shares the proxy's address, so the limits apply to all visitors together. Ten failed logins from anyone lock everyone out for 15 minutes.
Web Server Hardening
The included .htaccess files (Apache) block:
.gitand other hidden files- the
lib/directory - SQL, Markdown and ADIF files
config.local.php, the command-line loader and the ADIF parser- anything but images in
templates/
These rules only work when Apache reads .htaccess files. Set
AllowOverride All for the Firefly QSL directory, or at least
AllowOverride Options AuthConfig FileInfo.
On nginx, add the equivalent to the site's server block:
location ~ /\.(?!well-known/) { deny all; }
location ~ ^/(.*/)?lib/ { deny all; }
location ~ \.(sql|adi|adif|md|scss|map|bak|orig|swp|dist)$ { deny all; }
location ~ (config\.local|qsladifloader-cli|adif_parser)\.php$ { deny all; }
location ~ ^/(.*/)?templates/.*\.(?!(jpe?g|png|webp)$)[^/]+$ { deny all; }
Don't keep log files in the web directory
Upload logs through the loader instead of copying .adi
files onto the server next to the application.
The Installation Check
check_install.php shows server details such as installed PHP modules and
fonts. It only runs for a logged-in user, from the command line, or while
$install_check_enabled = true. Set that back to false as soon as the
install is working. See Command-Line Tools.