Re: [Twisted-Python] twisted.conch.ssh.session.SSHSession.request_subsystem

2008-12-22 Thread glyph
On 22 Dec, 07:10 pm, tzury...@gmail.com wrote: Glyph, thanks for your attention and time. I am afraid I was not clear wit hmy question so please allow me to elaborate. The way you control which paths a user can access in this scenario is by setting the filesystem permissions on those directori

Re: [Twisted-Python] twisted.conch.ssh.session.SSHSession.request_subsystem

2008-12-22 Thread Tzury Bar Yochay
I managed to hack this by patching the _absPath method as follows: # put in my main file def absPath(self, path): # users is my own object which manages the users in the system profile = users.get(self.avatar.username) if profile: home = self.avatar.getHomeDir() abspat

Re: [Twisted-Python] twisted.conch.ssh.session.SSHSession.request_subsystem

2008-12-22 Thread Tzury Bar Yochay
Glyph, thanks for your attention and time. I am afraid I was not clear wit hmy question so please allow me to elaborate. > The way you control which paths a user can access in this scenario is by > setting the filesystem permissions on those directories. Sorry, but Twisted > cannot magically chan

Re: [Twisted-Python] Re: How is happened?

2008-12-22 Thread Drew Smathers
On Mon, Dec 22, 2008 at 6:33 AM, Phil Mayers wrote: > biziap biziap wrote: >> >> >> 2008/12/22 biziap biziap mailto:fet...@gmail.com>> >> >>I am trying to migrate to web2. And find the "OldRequestAdapter". >>What I did is callling: >> >> Any hints are appericated. >> > > 1. Ask on the twi

Re: [Twisted-Python] twisted.conch.ssh.session.SSHSession.request_subsystem

2008-12-22 Thread glyph
On 01:45 pm, tzury...@gmail.com wrote: the code is available at: http://gist.github.com/37446 The point is that I am missing the knowledge needed in order to add path control. That is, controlling which path(s) a user can access. UnixSSHRealm is a realm which returns SSH avatars that, like Ope

[Twisted-Python] twisted.conch.ssh.session.SSHSession.request_subsystem

2008-12-22 Thread Tzury Bar Yochay
Hi all, I've managed to come up with a minimal sftp server implementation which able to auth users using rsa_key the code is available at: http://gist.github.com/37446 The point is that I am missing the knowledge needed in order to add path control. That is, controlling which path(s) a user can

Re: [Twisted-Python] Re: How is happened?

2008-12-22 Thread Phil Mayers
biziap biziap wrote: 2008/12/22 biziap biziap mailto:fet...@gmail.com>> I am trying to migrate to web2. And find the "OldRequestAdapter". What I did is callling: Any hints are appericated. 1. Ask on the twisted-web list 2. Don't use web2: http://twistedmatrix.com/trac/wiki

[Twisted-Python] Re: How is happened?

2008-12-22 Thread biziap biziap
2008/12/22 biziap biziap > I am trying to migrate to web2. And find the "OldRequestAdapter". > What I did is callling: > > ## in a resource of web2 > def render(self,web2_request): > request = twisted.web2.compat.makeOldRequestAdapter(web2_request) > ... > request.getSession() > >

[Twisted-Python] How is happened?

2008-12-22 Thread biziap biziap
I am trying to migrate to web2. And find the "OldRequestAdapter". What I did is callling: ## in a resource of web2 def render(self,web2_request): request = twisted.web2.compat.makeOldRequestAdapter(web2_request) File "c:\python25\Lib\site-packages\twisted\web2\compat.py", line 336, in get