예제 #1
0
파일: grid_ftps.py 프로젝트: heromod/migrid
 def validpath(self, path):
     """Check that user is allowed inside path checking against configured
     chroot_exceptions and built-in hidden paths.
     """
     daemon_conf = configuration.daemon_conf
     try:
         get_fs_path(path, daemon_conf['root_dir'],
                     daemon_conf['chroot_exceptions'])
         logger.debug("accepted access to %s" % path)
         return True
     except ValueError:
         logger.error("rejected access to %s" % path)
         return False