Python: Dennis Nedry - Security [closed]
Has anyone seen Jurrassic Park where Dennis Nedry has protected the system with an animation that says 'You didn't say the magic word' where after the system goes down.
Is it possible to do something similar ikn Python ?
To describe it less humoristic:
A response screen which waits for a condition fulfilled by the user. And encrypts and locks the system after a certain time.
Is that possible on a linux system by the use of Python ?
Yes, it is possible.
In which I attempt to answer the implied question, "And if so, how?"
I think this is really a Linux administration question. You'd have to figure out how to suspend a user's account on the system you're using and then log the current user out. It's likely going to involve the Python script running as a user with privileges greater than the user you're locking out. You don't really want to encrypt, do you? Just prevent access. Once you know how to accomplish all those things (suspend account / deny login, log out user, run script as privileged user, etc.,) it's easy to perform those tasks from a Python script.
精彩评论