On 7/11/06, <b class="gmail_sendername">Phillip J. Eby</b> <<a href="mailto:pje@telecommunity.com">pje@telecommunity.com</a>> wrote:<div><span class="gmail_quote"></span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
At 10:56 AM 7/11/2006 -0700, Brett Cannon wrote:<br>>On 7/10/06, Talin <<mailto:<a href="mailto:talin@acm.org">talin@acm.org</a>><a href="mailto:talin@acm.org">talin@acm.org</a>> wrote:<br>>>(Although, I've often wished for Python to have a variant of __call__
<br>>>that could be used to override individual methods, i.e.:<br>>><br>>> __call_method__( self, methodname, *args )<br><br>As with so many other things in this discussion, this was already invented
<br>by the Zope folks just shy of a decade ago. ;-) __call_method__ is<br>actually a feature of ExtensionClasses, although you can of course<br>implement it yourself now atop new-style classes.<br><br>For other things that Zope has already done in the area of restricted
<br>execution R&D, see:<br><br><a href="http://svn.zope.org/Zope3/trunk/src/zope/security/untrustedinterpreter.txt?view=auto">http://svn.zope.org/Zope3/trunk/src/zope/security/untrustedinterpreter.txt?view=auto</a><br>
<br>The surrounding directory has other documents regarding their approach.<br><br>I haven't been following this discussion closely, but a lot of the things<br>mentioned in this thread seem to have a lot in common with stuff the Zope
<br>folks have had in production for "untrusted" Python execution for some time<br>now, working with current versions of Python. It would be a shame to<br>reinvent all the same wheels, especially since their code is nicely
<br>documented complete with extensive doctests and explanations of the approach.</blockquote><div><br>Taking a proxy approach is just being discussed; it has not been decided as the proper solution. I have been considering just preventing direct 'file' access and using open() to act as a delegate for opening files. That approach has nothing to do with proxies.
<br><br>-Brett<br></div><br></div>