refactor indentation with hard tab

This commit is contained in:
Francois Perrad 2015-12-31 15:59:01 +01:00
parent 4c4aa502d4
commit 23ac7f56fa
5 changed files with 21 additions and 21 deletions

View File

@ -332,12 +332,12 @@ char* getpass_or_cancel(char* prompt)
char* password = NULL; char* password = NULL;
#ifdef DROPBEAR_PASSWORD_ENV #ifdef DROPBEAR_PASSWORD_ENV
/* Password provided in an environment var */ /* Password provided in an environment var */
password = getenv(DROPBEAR_PASSWORD_ENV); password = getenv(DROPBEAR_PASSWORD_ENV);
if (password) if (password)
{ {
return password; return password;
} }
#endif #endif
password = getpass(prompt); password = getpass(prompt);

View File

@ -238,13 +238,13 @@ int main(int argc, char ** argv) {
} }
check_signkey_bits(keytype, bits);; check_signkey_bits(keytype, bits);;
} }
fprintf(stderr, "Generating key, this may take a while...\n"); fprintf(stderr, "Generating key, this may take a while...\n");
if (signkey_generate(keytype, bits, filename) == DROPBEAR_FAILURE) if (signkey_generate(keytype, bits, filename) == DROPBEAR_FAILURE)
{ {
dropbear_exit("Failed to generate key.\n"); dropbear_exit("Failed to generate key.\n");
} }
printpubfile(filename); printpubfile(filename);

View File

@ -645,7 +645,7 @@ static void make_mac(unsigned int seqno, const struct key_context_directional *
dropbear_exit("HMAC error"); dropbear_exit("HMAC error");
} }
bufsize = MAX_MAC_LEN; bufsize = MAX_MAC_LEN;
if (hmac_done(&hmac, output_mac, &bufsize) != CRYPT_OK) { if (hmac_done(&hmac, output_mac, &bufsize) != CRYPT_OK) {
dropbear_exit("HMAC error"); dropbear_exit("HMAC error");
} }

10
rsa.c
View File

@ -69,12 +69,12 @@ int buf_get_rsa_pub_key(buffer* buf, dropbear_rsa_key *key) {
} }
TRACE(("leave buf_get_rsa_pub_key: success")) TRACE(("leave buf_get_rsa_pub_key: success"))
ret = DROPBEAR_SUCCESS; ret = DROPBEAR_SUCCESS;
out: out:
if (ret == DROPBEAR_FAILURE) { if (ret == DROPBEAR_FAILURE) {
m_free(key->e); m_free(key->e);
m_free(key->n); m_free(key->n);
} }
return ret; return ret;
} }

View File

@ -317,15 +317,15 @@ void buf_put_priv_key(buffer* buf, sign_key *key, enum signkey_type type) {
#ifdef DROPBEAR_DSS #ifdef DROPBEAR_DSS
if (type == DROPBEAR_SIGNKEY_DSS) { if (type == DROPBEAR_SIGNKEY_DSS) {
buf_put_dss_priv_key(buf, key->dsskey); buf_put_dss_priv_key(buf, key->dsskey);
TRACE(("leave buf_put_priv_key: dss done")) TRACE(("leave buf_put_priv_key: dss done"))
return; return;
} }
#endif #endif
#ifdef DROPBEAR_RSA #ifdef DROPBEAR_RSA
if (type == DROPBEAR_SIGNKEY_RSA) { if (type == DROPBEAR_SIGNKEY_RSA) {
buf_put_rsa_priv_key(buf, key->rsakey); buf_put_rsa_priv_key(buf, key->rsakey);
TRACE(("leave buf_put_priv_key: rsa done")) TRACE(("leave buf_put_priv_key: rsa done"))
return; return;
} }
#endif #endif
#ifdef DROPBEAR_ECDSA #ifdef DROPBEAR_ECDSA