<div>
                    I should mention that this scenario is the worst case scenario, and isn't the likely one. However I think the possible damages from it well outweigh the small amount of benefit from mutable packages.
                </div><div><br></div><div>The more likely scenarios (on the failure side) are either applications breaking upon install/deploy or silently corrupting data. Both of which, but especially the silently corrupting data case I think the possible damages again outweigh the small benefit from mutable packages.</div>
                <div></div>
                 
                <p style="color: #A0A0A8;">On Wednesday, February 1, 2012 at 6:06 AM, Yuval Greenfield wrote:</p>
                <blockquote type="cite" style="border-left-style:solid;border-width:1px;margin-left:0px;padding-left:10px;">
                    <span><div><div><div dir="ltr"><div>On Wed, Feb 1, 2012 at 11:14 AM, Chris Withers <span dir="ltr">&lt;<a href="mailto:chris@simplistix.co.uk">chris@simplistix.co.uk</a>&gt;</span> wrote:<br><blockquote type="cite"><div>
<div>On 01/02/2012 09:01, Yuval Greenfield wrote:<br><blockquote type="cite"><div>
Would you testify that HTTP is secure because I can emulate TLS in<br>
javascript?<br>
</div></blockquote><br></div>
What's that got to do with the price of eggs?<div><br>
<br></div></div></blockquote><div><br></div><div>I can maintain my own personal log of package SHA-512's and thus locally avoid this security hole in PyPI. The system as a whole is still vulnerable by default. That's why HTTP is considered insecure even though you can build secure solutions on top of it. PyPI would be&nbsp;the insecure infrastructure upon which secure frameworks can be built.&nbsp;Immutability will make the default behavior of pypi more secure.</div>
<div><br></div><div>&nbsp;</div><blockquote type="cite"><div><div><blockquote type="cite"><div>
PyPI should do what it can within reason to be consistent and safe for<br>
all its users.<br>
</div></blockquote><br></div>
*sigh* that's what the MD5s are for. What threat, exactly are you so worried about here? That someone investigates and chooses to use a package, and then, having done so, decides to re-download an identical version of that package which has been maliciously uploaded, and happens to have the same MD5 checksum as the one they've already downloaded?<div>
<div><br></div></div></div></blockquote><div><br></div><div>Let's assume I made a package called pybanker that requires a specific version of&nbsp;SQLAlchemy (eg 0.6.8). When I tell people to download&nbsp;SQLAlchemy&nbsp;0.6.8 do I have to tell them the exact hash? Does the <a href="http://setup.py/cfg">setup.py/cfg</a> allow me to require a specific hash on SQLAlchemy when automatically resolving dependencies in pip/easy_install? So now when banks around the world are going to use pybanker and thus SQLAlchemy 0.6.8 - they don't know what was the original hash. In the meantime a security threat has manifested in sqlalchemy (eg&nbsp;<span style="">pythonpackages was hacked, an sqlalchemy maintainer password/computer/network was compromised, etc). The hacker modifies&nbsp;</span>SQLAlchemy 0.6.8 to work perfectly while adding a backdoor to the system or relaying all transactions to a remote server.</div>
<div><br></div><div>I hope we don't have to wait for this attack vector to be used (and detected and publicized) before this loophole is patched.</div><div><br></div><div>Obviously this isn't the only problem if the account of an SQLAlchemy maintainer is compromised - other threats can manifest as well. That doesn't mean this specific threat should be ignored, especially considering that it's a stealthy vector.</div>
<div><br></div><div>tl;dr - the classic bait and switch is why user generated content is immutable on most web services. If edits are allowed they are usually only so for a limited amount of time or require an administrator in the loop.</div>
<div><br></div><div>Yuval</div></div></div>
</div><div><div>_______________________________________________</div><div>Catalog-SIG mailing list</div><div><a href="mailto:Catalog-SIG@python.org">Catalog-SIG@python.org</a></div><div><a href="http://mail.python.org/mailman/listinfo/catalog-sig">http://mail.python.org/mailman/listinfo/catalog-sig</a></div></div></div></span>
                 
                 
                 
                 
                </blockquote>
                 
                <div>
                    <br>
                </div>