eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'FTPSession':

Home

Documentation
www.exept.de
Everywhere
for:
[back]

Class: FTPSession


Inheritance:

   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

Description:


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.

copyright

COPYRIGHT (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.

Instance protocol:

basic ftp user commands
o  doDELETE: recursive
FOR NOW: DO NEVER delete, but always report an error

o  doLIST: longFormat
(comment from inherited method)
raise an error: must be redefined in concrete subclass(es)

o  doMKD: newDirectory
FOR NOW: DO NEVER create directory, but always report an error

o  doRETR: file onTo: outStream
(comment from inherited method)
raise an error: must be redefined in concrete subclass(es)

o  doSTORE: unique
FOR NOW: DO NEVER allow writing over an existing file

protocol operations
o  defaultDirectoryForUser: user
(comment from inherited method)
raise an error: must be redefined in concrete subclass(es)

protocol testing
o  canChangeWorkingDirectory: aDirectory
(comment from inherited method)
raise an error: must be redefined in concrete subclass(es)

o  checkPassword: aPassword for: aUser

o  loginUserNeedsPassword: aUser
checks whether user exists and need a password;
- if the user is not known by the system an exception is raised



ST/X 7.7.0.0; WebServer 1.702 at 20f6060372b9.unknown:8081; Tue, 10 Dec 2024 08:44:23 GMT