| 1 | '\" t
|
|---|
| 2 | .\" Title: vfs_scannedonly
|
|---|
| 3 | .\" Author: [see the "AUTHOR" section]
|
|---|
| 4 | .\" Generator: DocBook XSL Stylesheets v1.76.1 <http://docbook.sf.net/>
|
|---|
| 5 | .\" Date: 09/18/2013
|
|---|
| 6 | .\" Manual: System Administration tools
|
|---|
| 7 | .\" Source: Samba 3.6
|
|---|
| 8 | .\" Language: English
|
|---|
| 9 | .\"
|
|---|
| 10 | .TH "VFS_SCANNEDONLY" "8" "09/18/2013" "Samba 3\&.6" "System Administration tools"
|
|---|
| 11 | .\" -----------------------------------------------------------------
|
|---|
| 12 | .\" * Define some portability stuff
|
|---|
| 13 | .\" -----------------------------------------------------------------
|
|---|
| 14 | .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|---|
| 15 | .\" http://bugs.debian.org/507673
|
|---|
| 16 | .\" http://lists.gnu.org/archive/html/groff/2009-02/msg00013.html
|
|---|
| 17 | .\" ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
|
|---|
| 18 | .ie \n(.g .ds Aq \(aq
|
|---|
| 19 | .el .ds Aq '
|
|---|
| 20 | .\" -----------------------------------------------------------------
|
|---|
| 21 | .\" * set default formatting
|
|---|
| 22 | .\" -----------------------------------------------------------------
|
|---|
| 23 | .\" disable hyphenation
|
|---|
| 24 | .nh
|
|---|
| 25 | .\" disable justification (adjust text to left margin only)
|
|---|
| 26 | .ad l
|
|---|
| 27 | .\" -----------------------------------------------------------------
|
|---|
| 28 | .\" * MAIN CONTENT STARTS HERE *
|
|---|
| 29 | .\" -----------------------------------------------------------------
|
|---|
| 30 | .SH "NAME"
|
|---|
| 31 | vfs_scannedonly \- Ensures that only files that have been scanned for viruses are visible and accessible to the end user\&.
|
|---|
| 32 | .SH "SYNOPSIS"
|
|---|
| 33 | .HP \w'\ 'u
|
|---|
| 34 | vfs objects = scannedonly
|
|---|
| 35 | .SH "DESCRIPTION"
|
|---|
| 36 | .PP
|
|---|
| 37 | This VFS module is part of the
|
|---|
| 38 | \fBsamba\fR(8)
|
|---|
| 39 | suite\&.
|
|---|
| 40 | .PP
|
|---|
| 41 | The
|
|---|
| 42 | vfs_scannedonly
|
|---|
| 43 | VFS module ensures that only files that have been scanned for viruses are visible and accessible to the end user\&. If non\-scanned files are found an anti\-virus scanning daemon is notified\&. The anti\-virus scanning daemon is not part of the Samba suite\&.
|
|---|
| 44 | .PP
|
|---|
| 45 | Scannedonly comes in two parts: a samba vfs module and (one or more) daemons\&. The daemon scans files\&. If a certain file is clean, a second file is created with prefix
|
|---|
| 46 | \&.scanned:\&. The Samba module simply looks if such a
|
|---|
| 47 | \&.scanned:
|
|---|
| 48 | file exists, and is newer than the pertinent file\&. If this is the case, the file is shown to the user\&. If this is not the case, the file is not returned in a directory listing (configurable), and cannot be opened (configurable)\&. The Samba vfs module will notify the daemon to scan this file\&.
|
|---|
| 49 | .PP
|
|---|
| 50 | So what happens for the user in the default configuration\&. The first time a directory is listed, it shows files as \*(Aqfile is being scanned for viruses, but after the first time all files are shown\&. There is a utility scannedonly_prescan that can help you to prescan all directories\&. When new files are written the daemon is notified immediately after the file is complete\&.
|
|---|
| 51 | .PP
|
|---|
| 52 | If a virus is found by the daemon, a file with a warning message is created in the directory of the user, a warning is sent to the logs, and the file is renamed to have prefix
|
|---|
| 53 | \&.virus:\&. Files with the
|
|---|
| 54 | \&.virus:
|
|---|
| 55 | prefix are never shown to the user and all access is denied\&.
|
|---|
| 56 | .PP
|
|---|
| 57 | This module is stackable\&.
|
|---|
| 58 | .SH "CONFIGURATION"
|
|---|
| 59 | .PP
|
|---|
| 60 | vfs_scannedonly
|
|---|
| 61 | relies on a anti\-virus scanning daemon that listens on the scannedonly socket (unix domain socket or UDP socket)\&.
|
|---|
| 62 | .SH "OPTIONS"
|
|---|
| 63 | .PP
|
|---|
| 64 | scannedonly:domain_socket = True
|
|---|
| 65 | .RS 4
|
|---|
| 66 | Whether to use a unix domain socket or not (false reverts to use udp)
|
|---|
| 67 | .RE
|
|---|
| 68 | .PP
|
|---|
| 69 | scannedonly:socketname = /var/lib/scannedonly/scan
|
|---|
| 70 | .RS 4
|
|---|
| 71 | The location of the unix domain socket to connect to
|
|---|
| 72 | .RE
|
|---|
| 73 | .PP
|
|---|
| 74 | scannedonly:portnum = 2020
|
|---|
| 75 | .RS 4
|
|---|
| 76 | The udp port number to connect to
|
|---|
| 77 | .RE
|
|---|
| 78 | .PP
|
|---|
| 79 | scannedonly:scanhost = localhost
|
|---|
| 80 | .RS 4
|
|---|
| 81 | When using UDP the host that runs the scanning daemon (this host needs access to the files!)
|
|---|
| 82 | .RE
|
|---|
| 83 | .PP
|
|---|
| 84 | scannedonly:show_special_files = True
|
|---|
| 85 | .RS 4
|
|---|
| 86 | Whether sockets, devices and fifo\*(Aqs (all not scanned for viruses) should be visible to the user
|
|---|
| 87 | .RE
|
|---|
| 88 | .PP
|
|---|
| 89 | scannedonly:rm_hidden_files_on_rmdir = True
|
|---|
| 90 | .RS 4
|
|---|
| 91 | Whether files that are not visible (\&.scanned:
|
|---|
| 92 | files,
|
|---|
| 93 | \&.failed:
|
|---|
| 94 | files and
|
|---|
| 95 | \&.virus:
|
|---|
| 96 | files) should be deleted if the user tries to remove the directory\&. If false, the user will get the "directory is not empty" error\&.
|
|---|
| 97 | .RE
|
|---|
| 98 | .PP
|
|---|
| 99 | scannedonly:hide_nonscanned_files = True
|
|---|
| 100 | .RS 4
|
|---|
| 101 | If false, all non\-scanned files are visible in directory listings\&. If such files are found in a directory listing the scanning daemon is notified that scanning is required\&. Access to non\-scanned files is still denied (see scannedonly:allow_nonscanned_files)\&.
|
|---|
| 102 | .RE
|
|---|
| 103 | .PP
|
|---|
| 104 | scannedonly:scanning_message = is being scanned for viruses
|
|---|
| 105 | .RS 4
|
|---|
| 106 | If non\-scanned files are hidden (if scannedonly:hide_nonscanned_files = True), a fake 0 byte file is shown\&. The filename is the original filename with the message as suffix\&.
|
|---|
| 107 | .RE
|
|---|
| 108 | .PP
|
|---|
| 109 | scannedonly:recheck_time_open = 50
|
|---|
| 110 | .RS 4
|
|---|
| 111 | If a non\-scanned file is opened, the vfs module will wait recheck_tries_open times for recheck_time_open milliseconds for the scanning daemon to create a
|
|---|
| 112 | \&.scanned:
|
|---|
| 113 | file\&. For small files that are scanned by the daemon within the time (tries * time) the behavior will be just like on\-access scanning\&.
|
|---|
| 114 | .RE
|
|---|
| 115 | .PP
|
|---|
| 116 | scannedonly:recheck_tries_open = 100
|
|---|
| 117 | .RS 4
|
|---|
| 118 | See recheck_time_open\&.
|
|---|
| 119 | .RE
|
|---|
| 120 | .PP
|
|---|
| 121 | scannedonly:recheck_time_readdir = 50
|
|---|
| 122 | .RS 4
|
|---|
| 123 | If a non\-scanned file is in a directory listing the vfs module notifies the daemon (once for all files that need scanning in that directory), and waits recheck_tries_readdir times for recheck_time_readdir milliseconds\&. Only used when hide_nonscanned_files is false\&.
|
|---|
| 124 | .RE
|
|---|
| 125 | .PP
|
|---|
| 126 | scannedonly:recheck_tries_readdir = 20
|
|---|
| 127 | .RS 4
|
|---|
| 128 | See recheck_time_readdir\&.
|
|---|
| 129 | .RE
|
|---|
| 130 | .PP
|
|---|
| 131 | scannedonly:allow_nonscanned_files = False
|
|---|
| 132 | .RS 4
|
|---|
| 133 | Allow access to non\-scanned files\&. The daemon is notified, however, and special files such as
|
|---|
| 134 | \&.scanned:
|
|---|
| 135 | files\&.
|
|---|
| 136 | \&.virus:
|
|---|
| 137 | files and
|
|---|
| 138 | \&.failed:
|
|---|
| 139 | files are not listed\&.
|
|---|
| 140 | .RE
|
|---|
| 141 | .SH "EXAMPLES"
|
|---|
| 142 | .PP
|
|---|
| 143 | Enable anti\-virus scanning:
|
|---|
| 144 | .sp
|
|---|
| 145 | .if n \{\
|
|---|
| 146 | .RS 4
|
|---|
| 147 | .\}
|
|---|
| 148 | .nf
|
|---|
| 149 | \fI[homes]\fR
|
|---|
| 150 | \m[blue]\fBvfs objects = scannedonly\fR\m[]
|
|---|
| 151 | \m[blue]\fBscannedonly:hide_nonscanned_files = False\fR\m[]
|
|---|
| 152 | .fi
|
|---|
| 153 | .if n \{\
|
|---|
| 154 | .RE
|
|---|
| 155 | .\}
|
|---|
| 156 | .SH "CAVEATS"
|
|---|
| 157 | .PP
|
|---|
| 158 | This is not true on\-access scanning\&. However, it is very fast for files that have been scanned already\&.
|
|---|
| 159 | .SH "VERSION"
|
|---|
| 160 | .PP
|
|---|
| 161 | This man page is correct for version 3\&.6\&.0 of the Samba suite\&.
|
|---|
| 162 | .SH "AUTHOR"
|
|---|
| 163 | .PP
|
|---|
| 164 | The original Samba software and related utilities were created by Andrew Tridgell\&. Scannedonly was developed for Samba by Olivier Sessink\&. Samba is now developed by the Samba Team as an Open Source project similar to the way the Linux kernel is developed\&.
|
|---|