summaryrefslogtreecommitdiff
path: root/dss.c
diff options
context:
space:
mode:
authorMatt Johnston <matt@ucc.asn.au>2010-07-21 12:55:25 +0000
committerMatt Johnston <matt@ucc.asn.au>2010-07-21 12:55:25 +0000
commitfced1113d3dfbe6ee8ce8784ab75ae074a47e03b (patch)
tree6959f8ef7d3488ab5e198de958fbf52467218097 /dss.c
parent4d050c34cb96d07bef509eb537cde21faa987dbb (diff)
downloaddropbear-fced1113d3dfbe6ee8ce8784ab75ae074a47e03b.tar.gz
Rename rsa_key to dropbear_rsa_key (and same for dss too) so
we don't conflict with libtomcrypt. --HG-- extra : convert_revision : 77961344ec415d73d48fdc7b1ebead3099c13394
Diffstat (limited to 'dss.c')
-rw-r--r--dss.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/dss.c b/dss.c
index bcfbb61..2574e5f 100644
--- a/dss.c
+++ b/dss.c
@@ -43,7 +43,7 @@
* The key will have the same format as buf_put_dss_key.
* These should be freed with dss_key_free.
* Returns DROPBEAR_SUCCESS or DROPBEAR_FAILURE */
-int buf_get_dss_pub_key(buffer* buf, dss_key *key) {
+int buf_get_dss_pub_key(buffer* buf, dropbear_dss_key *key) {
TRACE(("enter buf_get_dss_pub_key"))
dropbear_assert(key != NULL);
@@ -76,7 +76,7 @@ int buf_get_dss_pub_key(buffer* buf, dss_key *key) {
/* Same as buf_get_dss_pub_key, but reads a private "x" key at the end.
* Loads a private dss key from a buffer
* Returns DROPBEAR_SUCCESS or DROPBEAR_FAILURE */
-int buf_get_dss_priv_key(buffer* buf, dss_key *key) {
+int buf_get_dss_priv_key(buffer* buf, dropbear_dss_key *key) {
int ret = DROPBEAR_FAILURE;
@@ -99,7 +99,7 @@ int buf_get_dss_priv_key(buffer* buf, dss_key *key) {
/* Clear and free the memory used by a public or private key */
-void dss_key_free(dss_key *key) {
+void dss_key_free(dropbear_dss_key *key) {
TRACE(("enter dsa_key_free"))
if (key == NULL) {
@@ -138,7 +138,7 @@ void dss_key_free(dss_key *key) {
* mpint g
* mpint y
*/
-void buf_put_dss_pub_key(buffer* buf, dss_key *key) {
+void buf_put_dss_pub_key(buffer* buf, dropbear_dss_key *key) {
dropbear_assert(key != NULL);
buf_putstring(buf, SSH_SIGNKEY_DSS, SSH_SIGNKEY_DSS_LEN);
@@ -150,7 +150,7 @@ void buf_put_dss_pub_key(buffer* buf, dss_key *key) {
}
/* Same as buf_put_dss_pub_key, but with the private "x" key appended */
-void buf_put_dss_priv_key(buffer* buf, dss_key *key) {
+void buf_put_dss_priv_key(buffer* buf, dropbear_dss_key *key) {
dropbear_assert(key != NULL);
buf_put_dss_pub_key(buf, key);
@@ -161,7 +161,7 @@ void buf_put_dss_priv_key(buffer* buf, dss_key *key) {
#ifdef DROPBEAR_SIGNKEY_VERIFY
/* Verify a DSS signature (in buf) made on data by the key given.
* returns DROPBEAR_SUCCESS or DROPBEAR_FAILURE */
-int buf_dss_verify(buffer* buf, dss_key *key, const unsigned char* data,
+int buf_dss_verify(buffer* buf, dropbear_dss_key *key, const unsigned char* data,
unsigned int len) {
unsigned char msghash[SHA1_HASH_SIZE];
@@ -292,7 +292,7 @@ static unsigned char* mptobytes(mp_int *mp, int *len) {
*
* Now we aren't relying on the random number generation to protect the private
* key x, which is a long term secret */
-void buf_put_dss_sign(buffer* buf, dss_key *key, const unsigned char* data,
+void buf_put_dss_sign(buffer* buf, dropbear_dss_key *key, const unsigned char* data,
unsigned int len) {
unsigned char msghash[SHA1_HASH_SIZE];