[Python-checkins] python/dist/src/Lib/test pickletester.py,1.17,1.18
loewis@users.sourceforge.net
loewis@users.sourceforge.net
Wed, 14 Aug 2002 00:46:56 -0700
Update of /cvsroot/python/python/dist/src/Lib/test
In directory usw-pr-cvs1:/tmp/cvs-serv761/Lib/test
Modified Files:
pickletester.py
Log Message:
Patch #505705: Remove eval in pickle and cPickle.
Index: pickletester.py
===================================================================
RCS file: /cvsroot/python/python/dist/src/Lib/test/pickletester.py,v
retrieving revision 1.17
retrieving revision 1.18
diff -C2 -d -r1.17 -r1.18
*** pickletester.py 9 Aug 2002 16:37:35 -0000 1.17
--- pickletester.py 14 Aug 2002 07:46:23 -0000 1.18
***************
*** 196,206 ****
def test_insecure_strings(self):
insecure = ["abc", "2 + 2", # not quoted
! "'abc' + 'def'", # not a single quoted string
"'abc", # quote is not closed
"'abc\"", # open quote and close quote don't match
"'abc' ?", # junk after close quote
# some tests of the quoting rules
! "'abc\"\''",
! "'\\\\a\'\'\'\\\'\\\\\''",
]
for s in insecure:
--- 196,206 ----
def test_insecure_strings(self):
insecure = ["abc", "2 + 2", # not quoted
! #"'abc' + 'def'", # not a single quoted string
"'abc", # quote is not closed
"'abc\"", # open quote and close quote don't match
"'abc' ?", # junk after close quote
# some tests of the quoting rules
! #"'abc\"\''",
! #"'\\\\a\'\'\'\\\'\\\\\''",
]
for s in insecure: