The predecessor to Armory (
PyBtcEngine) used pure-python implementation of ECDSA. This implementation was created by forum user "Lis" here:
https://bitcointalksearch.org/topic/solved-python-secp256k1-23241If you plug that into google translate, you'll see that he declared that code to be public domain. It's not exactly fast, but it most definitely works. I was able to create, sign, and verify blockchain transactions with it. It is based on python's native handling of arbitrary-sized integers -- go ahead, open a python shell and type "2**10000" ... you'll see what I mean
)
Not only can you verify that the code is just a basic EC library with hardcoded secp256k1 constants, it's stupid easy to wrap in a shell script to get whatever you need out of it. I would recommend using entropy generated from a reliable source (OpenSSL?), and pass that into Lis' script. His script uses the python "random" solely for testing that signing and verification work. But as is mentioned in python's own docs "python's PRNG is wholly unsuitable for cryptographic purposes".
EDIT: also, you can use armoryengine.py, but it doesn't use Lis' code anymore... it uses Crypto++ libraries made available to python via SWIG. It has turned out to be pretty simple to compile and run on any Linux (even OSX, because you can use armoryengine.py without any Qt dependencies). But that could be a lot of code just to get to its ECDSA implementation. (you can probably strip out 90% of armoryengine.py, though, and keep just the ECDSA parts)
Alternatively, you could extract
my wrapper around Crypto++ and use that somehow. It does exactly what you want, and you can use publicly-verifiable download the crypto++ libraries, which have no external dependencies. (use only SecureBinaryData objects and all methods below
this line).