Changeset 1269 for TI05-delivery


Ignore:
Timestamp:
03/07/06 15:55:19 (13 years ago)
Author:
spascoe
Message:

Added example client and server executables. Small bug fix.

Location:
TI05-delivery/trunk
Files:
3 added
2 edited

Legend:

Unmodified
Added
Removed
  • TI05-delivery/trunk/lib/python/delivery/server.py

    r1268 r1269  
    176176#-------------------------------------------------------------------------------------------------------------- 
    177177 
    178 class BasicClientAuthHandler(AuthHandler): 
    179     """ 
    180     This class makes communicating with the stand alone bbftp client slightly easier. 
    181     Mainly for use during testing. 
    182     """ 
    183  
    184     def recvCStr(self): 
    185         """Receive a message from the client which may contain \\0 characters indicating message end. 
    186  
    187         The message is truncated to the first \\0 character. 
    188  
    189         @return a string containing the message received. 
    190         """ 
    191  
    192         msg = self.recv() 
    193         # Trim to first '\0' 
    194         x = msg.find('\0') 
    195         if x: 
    196             msg = msg[:x] 
    197  
    198         return msg 
    199  
    200  
    201178 
    202179class LiberalAuthzHandler(AuthzHandler): 
  • TI05-delivery/trunk/test/test_embedded.py

    r1264 r1269  
    2727 
    2828 
    29 class TestAuthHandler(server.BasicClientAuthHandler): 
     29class TestAuthHandler(server.AuthHandler): 
    3030     
    3131    def authenticate(self): 
     
    7777        return self.authzPath(path) 
    7878 
    79     def authzSend(self, path): 
     79    def authzStore(self, path): 
    8080        return self.authzPath(path) 
    8181 
Note: See TracChangeset for help on using the changeset viewer.