| OLD | NEW |
| (Empty) | |
| 1 /** |
| 2 * @copyright |
| 3 * ==================================================================== |
| 4 * Copyright (c) 2008 CollabNet. All rights reserved. |
| 5 * |
| 6 * This software is licensed as described in the file COPYING, which |
| 7 * you should have received as part of this distribution. The terms |
| 8 * are also available at http://subversion.tigris.org/license-1.html. |
| 9 * If newer versions of this license are posted there, you may use a |
| 10 * newer version instead, at your option. |
| 11 * |
| 12 * This software consists of voluntary contributions made by many |
| 13 * individuals. For exact contribution history, see the revision |
| 14 * history and logs, available at http://subversion.tigris.org/. |
| 15 * ==================================================================== |
| 16 * @endcopyright |
| 17 * |
| 18 * @file svn_auth_private.h |
| 19 * @brief Subversion's authentication system - Internal routines |
| 20 */ |
| 21 |
| 22 #ifndef SVN_AUTH_PRIVATE_H |
| 23 #define SVN_AUTH_PRIVATE_H |
| 24 |
| 25 #ifdef __cplusplus |
| 26 extern "C" { |
| 27 #endif /* __cplusplus */ |
| 28 |
| 29 /* A function that stores in *PASSWORD (potentially after decrypting it) |
| 30 the user's password. It might be obtained directly from CREDS, or |
| 31 from an external store, using REALMSTRING and USERNAME as keys. |
| 32 If NON_INTERACTIVE is set, the user must not be involved in the |
| 33 retrieval process. POOL is used for any necessary allocation. */ |
| 34 typedef svn_boolean_t (*svn_auth__password_get_t) |
| 35 (const char **password, |
| 36 apr_hash_t *creds, |
| 37 const char *realmstring, |
| 38 const char *username, |
| 39 svn_boolean_t non_interactive, |
| 40 apr_pool_t *pool); |
| 41 |
| 42 /* A function that stores PASSWORD (or some encrypted version thereof) |
| 43 either directly in CREDS, or externally using REALMSTRING and USERNAME |
| 44 as keys into the external store. If NON_INTERACTIVE is set, the user |
| 45 must not be involved in the storage process. POOL is used for any |
| 46 necessary allocation. */ |
| 47 typedef svn_boolean_t (*svn_auth__password_set_t) |
| 48 (apr_hash_t *creds, |
| 49 const char *realmstring, |
| 50 const char *username, |
| 51 const char *password, |
| 52 svn_boolean_t non_interactive, |
| 53 apr_pool_t *pool); |
| 54 |
| 55 /* Common implementation for simple_first_creds and |
| 56 windows_simple_first_creds. Uses PARAMETERS, REALMSTRING and the |
| 57 simple auth provider's username and password cache to fill a set of |
| 58 CREDENTIALS. PASSWORD_GET is used to obtain the password value. |
| 59 PASSTYPE identifies the type of the cached password. CREDENTIALS are |
| 60 allocated from POOL. */ |
| 61 svn_error_t * |
| 62 svn_auth__simple_first_creds_helper(void **credentials, |
| 63 void **iter_baton, |
| 64 void *provider_baton, |
| 65 apr_hash_t *parameters, |
| 66 const char *realmstring, |
| 67 svn_auth__password_get_t password_get, |
| 68 const char *passtype, |
| 69 apr_pool_t *pool); |
| 70 |
| 71 /* Common implementation for simple_save_creds and |
| 72 windows_simple_save_creds. Uses PARAMETERS and REALMSTRING to save |
| 73 a set of CREDENTIALS to the simple auth provider's username and |
| 74 password cache. PASSWORD_SET is used to store the password. |
| 75 PASSTYPE identifies the type of the cached password. Allocates from POOL. */ |
| 76 svn_error_t * |
| 77 svn_auth__simple_save_creds_helper(svn_boolean_t *saved, |
| 78 void *credentials, |
| 79 void *provider_baton, |
| 80 apr_hash_t *parameters, |
| 81 const char *realmstring, |
| 82 svn_auth__password_set_t password_set, |
| 83 const char *passtype, |
| 84 apr_pool_t *pool); |
| 85 |
| 86 #ifdef __cplusplus |
| 87 } |
| 88 #endif /* __cplusplus */ |
| 89 |
| 90 #endif /* SVN_AUTH_PRIVATE_H */ |
| OLD | NEW |