Created by: ston1th 2019-04-16 21:03:02
Updated by: ston1th 2019-04-16 21:22:06
Visibility: Public

Document Store

FTP Server

This can be used for scanners with “scan to FTP” functionality.

Create scan user and directories:

groupadd scan
useradd -b /var -s /sbin/nologin -g scan scan
mkdir /var/scan
chown scan:scan /var/scan
chmod 755 /var/scan
echo scan > /etc/ftpchroot

Set the scan user password: passwd scan

Configure and start ftpd:

rcctl enable ftpd
rcctl set ftpd flags '-4lnU'
rcctl start ftpd

Add these rules to your pf.conf if needed:

lan = "<ip of LAN interface>"
printer = "<ip of scanner>"
pass in on $lan proto tcp from $scanner to $lan port 21
pass in on $lan proto tcp from $scanner to $lan port > 49151

Searchable document

tesseract -l deu+eng --oem 2 <scan>.jpg output.pdf pdf