0

the documentation is somehow sparse. I intend to use m2crypto in a webserver and it seems m2crypto.threading.init() shall be used.

Shall my python function called upon web request be something as:

def do_something():
   M2Crypto.threading.init()
   sign something with m2crypto
   M2Crypto.threading.cleanup()
   return httpresponse

or something else? Any web reference on this threading usage?

Thanks Nenad

Čikić Nenad
  • 392
  • 5
  • 13

1 Answers1

0

What is your deployment model? If you use something like mod_wsgi where you have separate processes, you need to set up threading just once during the lifetime of the python process.

Martin Paljak
  • 4,119
  • 18
  • 20