diff options
author | Sergey Poznyakoff <gray@gnu.org.ua> | 2005-02-25 16:33:01 +0000 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org.ua> | 2005-02-25 16:33:01 +0000 |
commit | 03923bb190326858461b62934b0a405d9f2f7b11 (patch) | |
tree | cdf9d8eb83fc0e2e9f498673b9f6cf05f162ee0d | |
parent | edfa04de0dd478c56beeed34054251f00cd74698 (diff) | |
download | mailutils-03923bb190326858461b62934b0a405d9f2f7b11.tar.gz mailutils-03923bb190326858461b62934b0a405d9f2f7b11.tar.bz2 |
(mu_sql_getpass)
(mu_sql_password_type,mu_sql_expand_query):
(mu_check_mysql_scrambled_password): New function
-rw-r--r-- | include/mailutils/sql.h | 27 |
1 files changed, 21 insertions, 6 deletions
diff --git a/include/mailutils/sql.h b/include/mailutils/sql.h index a3c89ec36..cb2c32b91 100644 --- a/include/mailutils/sql.h +++ b/include/mailutils/sql.h @@ -34,12 +34,13 @@ typedef void (*rdl_done_t) (void); mu_sql_dispatch_t __s_cat2__(mod,_dispatch_tab) #endif -enum mu_sql_connection_state { - mu_sql_not_connected, - mu_sql_connected, - mu_sql_query_run, - mu_sql_result_available -}; +enum mu_sql_connection_state + { + mu_sql_not_connected, + mu_sql_connected, + mu_sql_query_run, + mu_sql_result_available + }; typedef struct mu_sql_connection *mu_sql_connection_t; @@ -105,4 +106,18 @@ int mu_sql_get_column (mu_sql_connection_t conn, size_t nrow, size_t ncol, const char *mu_sql_strerror (mu_sql_connection_t conn); +enum mu_password_type + { + password_plaintext, /* Plaintext passwords */ + password_scrambled, /* Scrambled MySQL (>=3.21) password */ + password_hash, /* MD5 (or DES or whatever) hash */ + }; + +extern enum mu_password_type mu_sql_password_type; + +extern char *mu_sql_expand_query (const char *query, const char *ustr); +extern int mu_sql_getpass (const char *username, char **passwd); +extern int mu_check_mysql_scrambled_password (const char *scrambled, + const char *message); + #endif |