[Pycon] [new paper] "Hrvoje Gazibara" - Importing anything from anywhere

info a pycon.it info a pycon.it
Dom 6 Gen 2019 20:27:08 CET


Title: Importing anything from anywhere
Duration: 45 (includes Q&A)
Q&A Session: 0
Language: en
Type: Talk

Abstract: Python allows us to organize our code across files and folders easily, and only import the bits and pieces we need, whenever we need them. That scenario works excellent in case of plain-text Python code or bytecode stored on a local file system. What if the code is stored somewhere else, in some other format or even a different language?

During the talk, we will discover how Python 3 import system works, i.e., what happens after you type the import statement. We will also examine how to extend the import system with our logic and requirements. In the end, you will see how to abuse the import system's main phases - finding and loading - to import remote obfuscated Python code into our local scripts.

Join the talk if you've read that Python can load code from a zip file and have never had any idea how that's even possible. You're also welcome if you have ever imported anything and wondered which machinery is running in the background.


Tags: [u'finding', u'import_system', u'loading', u'python3']


Maggiori informazioni sulla lista Pycon