[Zope-Checkins] SVN: Zope/branches/2.10/ - Launchpad ##332168: Connection.py: do not expose DB connection strings

Andreas Jung andreas at andreas-jung.com
Sat Feb 21 10:28:10 EST 2009


Log message for revision 96951:
  
  - Launchpad ##332168: Connection.py: do not expose DB connection strings
    through exceptions
  

Changed:
  U   Zope/branches/2.10/doc/CHANGES.txt
  U   Zope/branches/2.10/lib/python/Shared/DC/ZRDB/Connection.py

-=-
Modified: Zope/branches/2.10/doc/CHANGES.txt
===================================================================
--- Zope/branches/2.10/doc/CHANGES.txt	2009-02-21 15:27:09 UTC (rev 96950)
+++ Zope/branches/2.10/doc/CHANGES.txt	2009-02-21 15:28:09 UTC (rev 96951)
@@ -27,6 +27,9 @@
 
     Bugs fixed
 
+      - Launchpad ##332168: Connection.py: do not expose DB connection strings
+        through exceptions
+
       - LP/#143873: Fixed problems when no HTTP_ACCEPT_CHARSET is in the
         request. This required an update of zope.publisher to 3.3.3.
 

Modified: Zope/branches/2.10/lib/python/Shared/DC/ZRDB/Connection.py
===================================================================
--- Zope/branches/2.10/lib/python/Shared/DC/ZRDB/Connection.py	2009-02-21 15:27:09 UTC (rev 96950)
+++ Zope/branches/2.10/lib/python/Shared/DC/ZRDB/Connection.py	2009-02-21 15:28:09 UTC (rev 96951)
@@ -191,9 +191,9 @@
             except:
                 t, v, tb = sys.exc_info()
                 raise BadRequest, (
-                    '<strong>Invalid connection string: </strong><CODE>%s</CODE><br>\n'
+                    '<strong>Error connecting to DB.</strong><br>\n'
                     '<!--\n%s\n%s\n-->\n'
-                    % (s,t,v)), tb
+                    % (t,v)), tb
         finally: tb=None
         self._v_connected=DateTime()
 



More information about the Zope-Checkins mailing list