xref: /freebsd/crypto/krb5/doc/html/_sources/appdev/refs/api/krb5_get_init_creds_password.rst.txt (revision 7f2fe78b9dd5f51c821d771b63d2e096f6fd49e9)
1krb5_get_init_creds_password -  Get initial credentials using a password.
2==========================================================================
3
4..
5
6.. c:function:: krb5_error_code krb5_get_init_creds_password(krb5_context context, krb5_creds * creds, krb5_principal client, const char * password, krb5_prompter_fct prompter, void * data, krb5_deltat start_time, const char * in_tkt_service, krb5_get_init_creds_opt * k5_gic_options)
7
8..
9
10
11:param:
12
13	          **[in]** **context** - Library context
14
15	          **[out]** **creds** - New credentials
16
17	          **[in]** **client** - Client principal
18
19	          **[in]** **password** - Password (or NULL)
20
21	          **[in]** **prompter** - Prompter function
22
23	          **[in]** **data** - Prompter callback data
24
25	          **[in]** **start_time** - Time when ticket becomes valid (0 for now)
26
27	          **[in]** **in_tkt_service** - Service name of initial credentials (or NULL)
28
29	          **[in]** **k5_gic_options** - Initial credential options
30
31
32..
33
34
35:retval:
36         -   0   Success
37         -   EINVAL   Invalid argument
38         -   KRB5_KDC_UNREACH   Cannot contact any KDC for requested realm
39         -   KRB5_PREAUTH_FAILED   Generic Pre-athentication failure
40         -   KRB5_LIBOS_PWDINTR   Password read interrupted
41         -   KRB5_REALM_CANT_RESOLVE   Cannot resolve network address for KDC in requested realm
42         -   KRB5KDC_ERR_KEY_EXP   Password has expired
43         -   KRB5_LIBOS_BADPWDMATCH   Password mismatch
44         -   KRB5_CHPW_PWDNULL   New password cannot be zero length
45         -   KRB5_CHPW_FAIL   Password change failed
46
47
48:return:
49         -  Kerberos error codes
50
51..
52
53
54
55
56
57
58
59This function requests KDC for an initial credentials for *client* using *password* . If *password* is NULL, a password will be prompted for using *prompter* if necessary. If *in_tkt_service* is specified, it is parsed as a principal name (with the realm ignored) and used as the service principal for the request; otherwise the ticket-granting service is used.
60
61
62
63
64
65
66
67
68
69
70..
71
72
73
74
75
76