|
Class: FTPSession
Object
|
+--AbstractTCPSession
|
+--AbstractFTPSession
|
+--FTPSession
- Package:
- stx:goodies/communication
- Category:
- Net-Communication-FTP
- Version:
- rev:
1.17
date: 2021/01/20 12:18:37
- user: cg
- file: FTPSession.st directory: goodies/communication
- module: stx stc-classLibrary: communication
Helper class for the FTPServer.
an FTP serverSession - subclass to add/change functionality
the server's functionality is limited (by purpose):
mkdir - never allowed (see doDelete:)
rmdir - never allowed (see doDelete:)
rm - never allowed (see doDelete:)
put - only allowed for new files
(i.e. existing files are never overwritten)
be aware, that this FTPSession allows a client to GET all files
which are readable by me (except for the white- and blacklists below).
To limit access to certain folders, you can explicitly whiteList
allowed folders (by setting whiteListedFolders) and/or exclude individual folders
via a blackList (setting blackListedFolders).
Whitelisting is done first, then blacklisting
i.e. it is possible to allow everything under '/foo/...' by adding '/foo' to the whitelist,
and still exclude individual subdirectories under it by adding (say) '/foo/bar/baz' to the blacklist.
copyrightCOPYRIGHT (c) 2003 by eXept Software AG
All Rights Reserved
This software is furnished under a license and may be used
only in accordance with the terms of that license and with the
inclusion of the above copyright notice. This software may not
be provided or otherwise made available to, or used by, any
other person. No title to or ownership of the software is
hereby transferred.
basic ftp user commands
-
doDELETE: recursive
-
FOR NOW: DO NEVER delete, but always report an error
-
doLIST: longFormat
-
(comment from inherited method)
raise an error: must be redefined in concrete subclass(es)
-
doMKD: newDirectory
-
FOR NOW: DO NEVER create directory, but always report an error
-
doRETR: file onTo: outStream
-
(comment from inherited method)
raise an error: must be redefined in concrete subclass(es)
-
doSTORE: unique
-
FOR NOW: DO NEVER allow writing over an existing file
protocol operations
-
defaultDirectoryForUser: user
-
(comment from inherited method)
raise an error: must be redefined in concrete subclass(es)
protocol testing
-
canChangeWorkingDirectory: aDirectory
-
(comment from inherited method)
raise an error: must be redefined in concrete subclass(es)
-
checkPassword: aPassword for: aUser
-
-
loginUserNeedsPassword: aUser
-
checks whether user exists and need a password;
- if the user is not known by the system an exception is raised
|