def sign_string_v2(string_to_sign):
 signature = base64.encodestring(hmac.new(Config.Config().secret_key, deunicodise(string_to_sign), sha1).digest()).strip()
 return signature

def sign_string_v2 ( string_to_sign ) : signature = base64 . encodestring ( hmac . new ( Config . Config ( ) . secret_key , deunicodise ( string_to_sign ) , sha1 ) . digest ( ) ) . strip ( ) return signature
sign a string with the secret key .