Skip to main content
Commonmark migration
Source Link

#CPython 3.6 import sys,os, ctypes, main f = open(file).read() if f.count("call") > 1: sys.exit() if len(f.splitlines()) != 21:ctypes.pythonapi.Py_AtExit(ctypes.pythonapi.Py_FatalError) type(ctypes.pythonapi).repr = repr(ctypes.pythonapi) def p(f,e,a): if e == 1 and a is not 2: try:3(f,e,a) finally:3(f,e,a) wipe = main.dict.clear c=p.code c=type(c)(3, 0, c.co_nlocals, c.co_stacksize, c.co_flags, c.co_code, (None, "c_call",wipe, p), c.co_names, c.co_varnames, c.co_filename, c.co_name, c.co_firstlineno, c.co_lnotab) p.code = c g=getattr s=sys.setprofile for mod in sys.modules.values(): if g(mod,"name",None) != "main":mod.dict.clear() s(p) wipe()

CPython 3.6

import sys,os, ctypes, __main__
f = open(__file__).read()
if f.count("__call__") > 1: sys.exit()
if len(f.splitlines()) != 21:ctypes.pythonapi.Py_AtExit(ctypes.pythonapi.Py_FatalError)
type(ctypes.pythonapi).repr = repr(ctypes.pythonapi)
def p(f,e,a):
 if e == 1 and a is not 2:
    try:3(f,e,a)
    finally:3(f,e,a)
wipe = __main__.__dict__.clear
c=p.__code__
c=type(c)(3, 0, c.co_nlocals, c.co_stacksize, c.co_flags, c.co_code,
                    (None, "c_call",wipe, p), c.co_names, c.co_varnames,
                    c.co_filename, c.co_name, c.co_firstlineno, c.co_lnotab)
p.__code__ = c
g=getattr
s=sys.setprofile
for mod in sys.modules.values():
    if g(mod,"__name__",None) != "__main__":mod.__dict__.clear()
s(p)
wipe()

(trailing newline at end)

Congratulations, Veedrac, zbw, and Dennis! You've cracked all three of my Python solutions. but now, can you crack them all together?! Input from STDIN, output to STDERR (which, per the rules, needs to be clean and not contain a Fatal Python error:, which the ctypes handler will print). The profile hook crashes by causing a recursion error handling a recursion error in order to make sure it isn't abused as an exit method. I wonder how long this will take to be cracked ...

#CPython 3.6 import sys,os, ctypes, main f = open(file).read() if f.count("call") > 1: sys.exit() if len(f.splitlines()) != 21:ctypes.pythonapi.Py_AtExit(ctypes.pythonapi.Py_FatalError) type(ctypes.pythonapi).repr = repr(ctypes.pythonapi) def p(f,e,a): if e == 1 and a is not 2: try:3(f,e,a) finally:3(f,e,a) wipe = main.dict.clear c=p.code c=type(c)(3, 0, c.co_nlocals, c.co_stacksize, c.co_flags, c.co_code, (None, "c_call",wipe, p), c.co_names, c.co_varnames, c.co_filename, c.co_name, c.co_firstlineno, c.co_lnotab) p.code = c g=getattr s=sys.setprofile for mod in sys.modules.values(): if g(mod,"name",None) != "main":mod.dict.clear() s(p) wipe()

(trailing newline at end)

Congratulations, Veedrac, zbw, and Dennis! You've cracked all three of my Python solutions. but now, can you crack them all together?! Input from STDIN, output to STDERR (which, per the rules, needs to be clean and not contain a Fatal Python error:, which the ctypes handler will print). The profile hook crashes by causing a recursion error handling a recursion error in order to make sure it isn't abused as an exit method. I wonder how long this will take to be cracked ...

CPython 3.6

import sys,os, ctypes, __main__
f = open(__file__).read()
if f.count("__call__") > 1: sys.exit()
if len(f.splitlines()) != 21:ctypes.pythonapi.Py_AtExit(ctypes.pythonapi.Py_FatalError)
type(ctypes.pythonapi).repr = repr(ctypes.pythonapi)
def p(f,e,a):
 if e == 1 and a is not 2:
    try:3(f,e,a)
    finally:3(f,e,a)
wipe = __main__.__dict__.clear
c=p.__code__
c=type(c)(3, 0, c.co_nlocals, c.co_stacksize, c.co_flags, c.co_code,
                    (None, "c_call",wipe, p), c.co_names, c.co_varnames,
                    c.co_filename, c.co_name, c.co_firstlineno, c.co_lnotab)
p.__code__ = c
g=getattr
s=sys.setprofile
for mod in sys.modules.values():
    if g(mod,"__name__",None) != "__main__":mod.__dict__.clear()
s(p)
wipe()

(trailing newline at end)

Congratulations, Veedrac, zbw, and Dennis! You've cracked all three of my Python solutions. but now, can you crack them all together?! Input from STDIN, output to STDERR (which, per the rules, needs to be clean and not contain a Fatal Python error:, which the ctypes handler will print). The profile hook crashes by causing a recursion error handling a recursion error in order to make sure it isn't abused as an exit method. I wonder how long this will take to be cracked ...

Rollback to Revision 4
Source Link
mbomb007
  • 23.5k
  • 7
  • 63
  • 135

#CPython 3.6, 731 bytes import sys,os, ctypes, main f = open(file).read() if f.count("call") > 1: sys.exit() if len(f.splitlines()) != 21:ctypes.pythonapi.Py_AtExit(ctypes.pythonapi.Py_FatalError) type(ctypes.pythonapi).repr = repr(ctypes.pythonapi) def p(f,e,a): if e == 1 and a is not 2: try:3(f,e,a) finally:3(f,e,a) wipe = main.dict.clear c=p.code c=type(c)(3, 0, c.co_nlocals, c.co_stacksize, c.co_flags, c.co_code, (None, "c_call",wipe, p), c.co_names, c.co_varnames, c.co_filename, c.co_name, c.co_firstlineno, c.co_lnotab) p.code = c g=getattr s=sys.setprofile for mod in sys.modules.values(): if g(mod,"name",None) != "main":mod.dict.clear() s(p) wipe()

(trailing newline at end)

Congratulations, Veedrac, zbw, and Dennis! You've cracked all three of my Python solutions. but now, can you crack them all together?! Input from STDIN, output to STDERR (which, per the rules, needs to be clean and not contain a Fatal Python error:, which the ctypes handler will print). The profile hook crashes by causing a recursion error handling a recursion error in order to make sure it isn't abused as an exit method. I wonder how long this will take to be cracked ...

#CPython 3.6, 731 bytes import sys,os, ctypes, main f = open(file).read() if f.count("call") > 1: sys.exit() if len(f.splitlines()) != 21:ctypes.pythonapi.Py_AtExit(ctypes.pythonapi.Py_FatalError) type(ctypes.pythonapi).repr = repr(ctypes.pythonapi) def p(f,e,a): if e == 1 and a is not 2: try:3(f,e,a) finally:3(f,e,a) wipe = main.dict.clear c=p.code c=type(c)(3, 0, c.co_nlocals, c.co_stacksize, c.co_flags, c.co_code, (None, "c_call",wipe, p), c.co_names, c.co_varnames, c.co_filename, c.co_name, c.co_firstlineno, c.co_lnotab) p.code = c g=getattr s=sys.setprofile for mod in sys.modules.values(): if g(mod,"name",None) != "main":mod.dict.clear() s(p) wipe()

(trailing newline at end)

Congratulations, Veedrac, zbw, and Dennis! You've cracked all three of my Python solutions. but now, can you crack them all together?! Input from STDIN, output to STDERR (which, per the rules, needs to be clean and not contain a Fatal Python error:, which the ctypes handler will print). The profile hook crashes by causing a recursion error handling a recursion error in order to make sure it isn't abused as an exit method. I wonder how long this will take to be cracked ...

#CPython 3.6 import sys,os, ctypes, main f = open(file).read() if f.count("call") > 1: sys.exit() if len(f.splitlines()) != 21:ctypes.pythonapi.Py_AtExit(ctypes.pythonapi.Py_FatalError) type(ctypes.pythonapi).repr = repr(ctypes.pythonapi) def p(f,e,a): if e == 1 and a is not 2: try:3(f,e,a) finally:3(f,e,a) wipe = main.dict.clear c=p.code c=type(c)(3, 0, c.co_nlocals, c.co_stacksize, c.co_flags, c.co_code, (None, "c_call",wipe, p), c.co_names, c.co_varnames, c.co_filename, c.co_name, c.co_firstlineno, c.co_lnotab) p.code = c g=getattr s=sys.setprofile for mod in sys.modules.values(): if g(mod,"name",None) != "main":mod.dict.clear() s(p) wipe()

(trailing newline at end)

Congratulations, Veedrac, zbw, and Dennis! You've cracked all three of my Python solutions. but now, can you crack them all together?! Input from STDIN, output to STDERR (which, per the rules, needs to be clean and not contain a Fatal Python error:, which the ctypes handler will print). The profile hook crashes by causing a recursion error handling a recursion error in order to make sure it isn't abused as an exit method. I wonder how long this will take to be cracked ...

added 11 characters in body
Source Link
mbomb007
  • 23.5k
  • 7
  • 63
  • 135

#CPython 3.6, 731 bytes import sys,os, ctypes, main f = open(file).read() if f.count("call") > 1: sys.exit() if len(f.splitlines()) != 21:ctypes.pythonapi.Py_AtExit(ctypes.pythonapi.Py_FatalError) type(ctypes.pythonapi).repr = repr(ctypes.pythonapi) def p(f,e,a): if e == 1 and a is not 2: try:3(f,e,a) finally:3(f,e,a) wipe = main.dict.clear c=p.code c=type(c)(3, 0, c.co_nlocals, c.co_stacksize, c.co_flags, c.co_code, (None, "c_call",wipe, p), c.co_names, c.co_varnames, c.co_filename, c.co_name, c.co_firstlineno, c.co_lnotab) p.code = c g=getattr s=sys.setprofile for mod in sys.modules.values(): if g(mod,"name",None) != "main":mod.dict.clear() s(p) wipe()

(trailing newline at end)

Congratulations, Veedrac, zbw, and Dennis! You've cracked all three of my Python solutions. but now, can you crack them all together?! Input from STDIN, output to STDERR (which, per the rules, needs to be clean and not contain a Fatal Python error:, which the ctypes handler will print). The profile hook crashes by causing a recursion error handling a recursion error in order to make sure it isn't abused as an exit method. I wonder how long this will take to be cracked ...

#CPython 3.6 import sys,os, ctypes, main f = open(file).read() if f.count("call") > 1: sys.exit() if len(f.splitlines()) != 21:ctypes.pythonapi.Py_AtExit(ctypes.pythonapi.Py_FatalError) type(ctypes.pythonapi).repr = repr(ctypes.pythonapi) def p(f,e,a): if e == 1 and a is not 2: try:3(f,e,a) finally:3(f,e,a) wipe = main.dict.clear c=p.code c=type(c)(3, 0, c.co_nlocals, c.co_stacksize, c.co_flags, c.co_code, (None, "c_call",wipe, p), c.co_names, c.co_varnames, c.co_filename, c.co_name, c.co_firstlineno, c.co_lnotab) p.code = c g=getattr s=sys.setprofile for mod in sys.modules.values(): if g(mod,"name",None) != "main":mod.dict.clear() s(p) wipe()

(trailing newline at end)

Congratulations, Veedrac, zbw, and Dennis! You've cracked all three of my Python solutions. but now, can you crack them all together?! Input from STDIN, output to STDERR (which, per the rules, needs to be clean and not contain a Fatal Python error:, which the ctypes handler will print). The profile hook crashes by causing a recursion error handling a recursion error in order to make sure it isn't abused as an exit method. I wonder how long this will take to be cracked ...

#CPython 3.6, 731 bytes import sys,os, ctypes, main f = open(file).read() if f.count("call") > 1: sys.exit() if len(f.splitlines()) != 21:ctypes.pythonapi.Py_AtExit(ctypes.pythonapi.Py_FatalError) type(ctypes.pythonapi).repr = repr(ctypes.pythonapi) def p(f,e,a): if e == 1 and a is not 2: try:3(f,e,a) finally:3(f,e,a) wipe = main.dict.clear c=p.code c=type(c)(3, 0, c.co_nlocals, c.co_stacksize, c.co_flags, c.co_code, (None, "c_call",wipe, p), c.co_names, c.co_varnames, c.co_filename, c.co_name, c.co_firstlineno, c.co_lnotab) p.code = c g=getattr s=sys.setprofile for mod in sys.modules.values(): if g(mod,"name",None) != "main":mod.dict.clear() s(p) wipe()

(trailing newline at end)

Congratulations, Veedrac, zbw, and Dennis! You've cracked all three of my Python solutions. but now, can you crack them all together?! Input from STDIN, output to STDERR (which, per the rules, needs to be clean and not contain a Fatal Python error:, which the ctypes handler will print). The profile hook crashes by causing a recursion error handling a recursion error in order to make sure it isn't abused as an exit method. I wonder how long this will take to be cracked ...

added 138 characters in body
Source Link
The Fifth Marshal
  • 6.3k
  • 1
  • 25
  • 44
Loading
added 270 characters in body
Source Link
The Fifth Marshal
  • 6.3k
  • 1
  • 25
  • 44
Loading
Post Undeleted by The Fifth Marshal
Post Deleted by The Fifth Marshal
deleted 20 characters in body
Source Link
The Fifth Marshal
  • 6.3k
  • 1
  • 25
  • 44
Loading
Source Link
The Fifth Marshal
  • 6.3k
  • 1
  • 25
  • 44
Loading