| /freebsd/crypto/krb5/src/appl/gss-sample/ |
| H A D | t_gss_sample.py | 32 def run_client_server(realm, options, server_options, **kwargs): argument 33 portstr = str(realm.server_port()) 36 server = realm.start_server(server_args, 'starting...') 37 realm.run([gss_client, '-port', portstr] + options + 54 def server_client_test(realm, options, server_options): argument 55 run_client_server(realm, options, server_options, 59 def ccache_savefile(realm): argument 60 return os.path.join(realm.testdir, 'ccache.copy') 63 def ccache_save(realm): argument 64 os.rename(realm.ccache, ccache_savefile(realm)) [all …]
|
| /freebsd/crypto/krb5/src/clients/kvno/ |
| H A D | t_kvno.py | 3 realm = K5Realm() variable 7 lines = realm.run([klist, '-c', ccache]).splitlines() 26 realm.run([kvno, realm.user_princ], expected_msg='user@KRBTEST.COM: kvno = 1') 27 check_cache(realm.ccache, [realm.krbtgt_princ, realm.user_princ]) 32 realm.run([kvno, '-e', 'camellia128-cts', realm.host_princ], 36 realm.run([kvno, '--cached-only', realm.user_princ], expected_msg='kvno = 1') 37 realm.run([kvno, '--cached-only', realm.host_princ], 39 check_cache(realm.ccache, [realm.krbtgt_princ, realm.user_princ]) 42 realm.run([kvno, '--no-store', realm.host_princ], expected_msg='kvno = 1') 43 check_cache(realm.ccache, [realm.krbtgt_princ, realm.user_princ]) [all …]
|
| /freebsd/crypto/krb5/src/lib/krb5/krb/ |
| H A D | t_vfy_increds.py | 25 realm = K5Realm() variable 27 # Verify the default test realm credentials with the default keytab. 29 realm.run(['./t_vfy_increds']) 30 realm.run(['./t_vfy_increds', '-n']) 35 realm.run([kadminl, 'ktadd', realm.host_princ]) 36 realm.run(['./t_vfy_increds']) 37 realm.run(['./t_vfy_increds', '-n']) 42 realm.run([kadminl, 'change_password', '-randkey', realm.host_princ]) 43 realm.run(['./t_vfy_increds'], expected_code=1) 44 realm.run(['./t_vfy_increds', '-n'], expected_code=1) [all …]
|
| H A D | t_in_ccache_patypes.py | 26 realm = K5Realm(create_user=False, create_host=False) variable 29 realm.run([kadminl, 'addprinc', '-pw', 'pass', 'nopreauth']) 30 realm.run([kadminl, 'addprinc', '-pw', 'pass', '+requires_preauth', 'preauth']) 34 realm.run(['./t_in_ccache', 'nopreauth', 'pass']) 38 realm.run(['./t_in_ccache', 'preauth', 'pass']) 42 realm.run(['./t_in_ccache', 'nopreauth', 'pass']) 43 realm.run(['./t_in_ccache', '-I', realm.ccache, 'preauth', 'pass']) 46 realm.run(['./t_in_ccache', 'preauth', 'pass']) 47 realm.run(['./t_in_ccache', '-I', realm.ccache, 'preauth', 'pass']) 52 realm.run(['./t_in_ccache', 'nopreauth', 'pass']) [all …]
|
| H A D | t_get_etype_info.py | 4 realm = K5Realm(create_host=False, krb5_conf=conf) variable 6 realm.run([kadminl, 'ank', '-pw', 'pw', '+preauth', 'puser']) 7 realm.run([kadminl, 'ank', '-nokey', 'nokey']) 8 realm.run([kadminl, 'ank', '-nokey', '+preauth', 'pnokey']) 9 realm.run([kadminl, 'ank', '-e', 'aes256-cts:special', '-pw', 'pw', 'exp']) 10 realm.run([kadminl, 'ank', '-e', 'aes256-cts:special', '-pw', 'pw', '+preauth', 14 out = realm.run([kdb5_util, 'tabdump', 'keyinfo']) 20 out = realm.run(['./t_get_etype_info', 'notfound'], expected_code=1, 26 realm.run(['./t_get_etype_info', 'user'], 28 realm.run(['./t_get_etype_info', 'puser'], [all …]
|
| H A D | get_creds.c | 169 * 1. Get a TGT for the service principal's realm (STATE_GET_TGT). 171 * 3. In some cases, get a TGT for the fallback realm (STATE_GET_TGT again). 185 STATE_GET_TGT, /* Getting TGT for service realm */ 202 krb5_data start_realm; /* Realm of starting TGT in ccache */ 207 krb5_boolean referral_req; /* Server initially contained referral realm */ 225 krb5_data *realm_path; /* Path from client to server realm */ 226 const krb5_data *last_realm;/* Last realm in realm_path */ 228 const krb5_data *next_realm;/* Current target realm in realm_path */ 239 krb5_data *caller_realm; /* Caller's realm parameter */ 250 * Fill in the caller out, realm, and flags output variables. out is filled in [all …]
|
| H A D | parse.c | 34 * whether name contains a realm separator. 57 princ->realm = empty_data(); in allocate_princ() 65 * shouldn't see this in the realm name. */ in allocate_princ() 66 if (cur_data == &princ->realm) { in allocate_princ() 81 /* Realm separator. In enterprise principals, the first one of in allocate_princ() 83 if (cur_data == &princ->realm) { in allocate_princ() 87 cur_data = &princ->realm; in allocate_princ() 89 /* Component or realm character, possibly quoted. Make note if in allocate_princ() 104 /* Allocate space for each component and the realm, with space for null in allocate_princ() 111 princ->realm.data = k5alloc(princ->realm.length + 1, &ret); in allocate_princ() [all …]
|
| /freebsd/crypto/krb5/src/lib/krb5/ccache/ |
| H A D | t_cccol.py | 3 realm = K5Realm(create_kdb=False) variable 6 out = realm.run([klist, '-c', 'KEYRING:process:abcd'], expected_code=1) 13 realm.run(['./t_cccol', 'DIR:' + os.path.join(realm.testdir, 'cc')]) 16 out = realm.run(['keyctl', 'list', anchor]) 18 keyid = realm.run(['keyctl', 'search', anchor, 'keyring', name]) 19 realm.run(['keyctl', 'unlink', keyid.strip(), anchor]) 23 cname = realm.testdir 34 realm.run(['./t_cccol', 'KEYRING:' + cname]) 36 realm.run(['./t_cccol', 'KEYRING:legacy:' + cname]) 38 realm.run(['./t_cccol', 'KEYRING:session:' + cname]) [all …]
|
| /freebsd/crypto/krb5/src/clients/ksu/ |
| H A D | t_ksu.py | 68 # Make krb5.conf a copy of realm's krb5.conf file. Save the old 71 def setup_krb5_conf(realm): argument 76 shutil.copyfile(os.path.join(realm.testdir, 'krb5.conf'), krb5_conf) 104 # Set up a realm. Set default_keytab_name since ksu won't respect the 107 realm = K5Realm(create_user=False, variable 109 realm.addprinc('alice', 'pwalice') 110 realm.addprinc('ksutest', 'pwksutest') 111 realm.addprinc('ksutest/root', 'pwroot') 112 realm.addprinc(caller_username, 'pwcaller') 115 # - /etc/krb5.conf is a copy of the test realm krb5.conf [all …]
|
| /freebsd/crypto/krb5/src/kdc/ |
| H A D | t_sockact.py | 7 kdc_conf = {'realms': {'$realm': { 10 realm = K5Realm(kdc_conf=kdc_conf, start_kdc=False) variable 14 realm.start_server(['./t_sockact', os.path.join(realm.testdir, 'sock1'), 15 str(realm.portbase + 8), '--', krb5kdc, '-n'], 19 cconf1 = {'realms': {'$realm': {'kdc': '$testdir/sock1'}}} 20 env1 = realm.special_env('sock1', False, krb5_conf=cconf1) 21 realm.kinit(realm.user_princ, password('user'), env=env1) 24 cconf2 = {'realms': {'$realm': {'kdc': '$hostname:$port8'}}} 25 env2 = realm.special_env('sock1', False, krb5_conf=cconf2) 26 realm.kinit(realm.user_princ, password('user'), env=env2) [all …]
|
| H A D | kdc_transit.c | 72 * add_to_transited Adds the name of the realm which issued the 75 * the realm of the server listed in the ticket 80 * in compressed form. It will add the new realm while 82 * realm is added using this (or a similar) routine, the 90 * This includes the realm of the KDC 92 * ticket. This is the realm that is 118 * and the realm to be added. This length is calculated 119 * assuming that no compression of the new realm is possible. 126 * This procedure does not check for quoted commas in realm 149 char *realm; in add_to_transited() local [all …]
|
| H A D | realm_data.h | 38 * General Kerberos per-realm data. 40 char * realm_name; /* Realm name */ 42 * The db_context is then associated with the realm keytab using 45 krb5_context realm_context; /* Context to be used for realm */ 46 krb5_keytab realm_keytab; /* keytab to be used for this realm */ 50 * Database per-realm data. 52 char * realm_stash; /* Stash file name for realm */ 53 char * realm_mpname; /* Master principal name for realm */ 54 krb5_principal realm_mprinc; /* Master principal for realm */ 59 krb5_keyblock realm_mkey; /* Master key for this realm */ [all …]
|
| /freebsd/crypto/heimdal/doc/ |
| H A D | setup.texi | 3 @node Setting up a realm, Applications, Building and Installing, Top 5 @chapter Setting up a realm 8 @cindex realm 9 realm is an administrative domain. The name of a Kerberos realm is 10 usually the Internet domain name in uppercase. Call your realm the same 27 * Cross realm:: 36 @node Configuration file, Creating the database, Setting up a realm, Setting up a realm 39 To setup a realm you will first have to create a configuration file: 78 parameters, such as the default realm and the timeout for KDC 86 To continue with the realm setup, you will have to create a configuration file, [all …]
|
| /freebsd/contrib/pam-krb5/tests/module/ |
| H A D | realm-t.c | 2 * Authentication tests for realm support in pam-krb5. 4 * Test the realm and user_realm option in the PAM configuration, which is 47 /* Start with a nonexistent default realm for authentication failure. */ in main() 50 run_script("data/scripts/realm/fail-no-realm", &config); in main() 51 run_script("data/scripts/realm/fail-no-realm-debug", &config); in main() 53 /* Running a script that sets realm properly should pass. */ in main() 54 config.extra[0] = krbconf->realm; in main() 55 run_script("data/scripts/realm/pass-realm", &config); in main() 58 run_script("data/scripts/realm/fail-user-realm", &config); in main() 74 run_script("data/scripts/realm/pass-user-realm", &config); in main() [all …]
|
| /freebsd/crypto/krb5/src/lib/kadm5/ |
| H A D | t_kadm5.py | 5 conf = {'realms': {'$realm': {'supported_enctypes': supported_enctypes}}} 6 realm = K5Realm(create_user=False, create_host=False, kdc_conf=conf) variable 8 with open(os.path.join(realm.testdir, 'acl'), 'w') as f: 18 with open(os.path.join(realm.testdir, 'dictfile'), 'w') as f: 25 realm.start_kadmind() 27 realm.run([kadminl, 'addpol', '-maxlife', '10000s', '-minlength', '8', 31 realm.run([kadminl, 'addpol', '-minlife', '10s', 'minlife-pol']) 32 realm.run([kadminl, 'addpol', 'dict-only-pol']) 33 realm.run([kadminl, 'addprinc', '-pw', 'admin', 'admin']) 34 realm.run([kadminl, 'addprinc', '-pw', 'admin', 'admin/get']) [all …]
|
| /freebsd/crypto/heimdal/kuser/ |
| H A D | kdigest.8 | 66 .Op Fl Fl realm= Ns Ar string 71 .Fl Fl realm= Ns Ar string 73 Kerberos realm to communicate with 77 .Op Fl Fl kerberos-realm= Ns Ar realm 82 .Op Fl Fl realm= Ns Ar string 90 .Fl Fl kerberos-realm= Ns Ar realm 109 .Fl Fl realm= Ns Ar string 111 Kerberos realm to communicate with 115 .Op Fl Fl kerberos-realm= Ns Ar realm 123 .Op Fl Fl realm= Ns Ar realm [all …]
|
| /freebsd/crypto/krb5/src/util/ |
| H A D | k5test.py | 36 for realm in multipass_realms(): 37 realm.run(['./testprog', 'arg']) 40 realm = K5Realm() 41 realm.start_server(['./serverprog'], 'starting...') 42 realm.run(['./clientprog', realm.host_princ]) 47 By default, the realm will have: 54 * Principals named realm.user_princ and realm.admin_princ; call 56 * Credentials for realm.user_princ in realm.ccache 57 * Admin rights for realm.admin_princ in the kadmind acl file 58 * A host principal named realm.host_princ with a random key [all …]
|
| /freebsd/crypto/heimdal/doc/doxyout/krb5/man/man3/ |
| H A D | krb5_principal.3 | 49 …b5_principal_set_realm\fP (krb5_context context, krb5_principal principal, krb5_const_realm realm)" 52 …incipal\fP (krb5_context context, krb5_principal *principal, int rlen, krb5_const_realm realm,...)" 55 …b5_make_principal\fP (krb5_context context, krb5_principal *principal, krb5_const_realm realm,...)" 87 …incipal (krb5_context context, krb5_principal * principal, int rlen, krb5_const_realm realm, ...)" 97 \fIrlen\fP length of realm 99 \fIrealm\fP realm name 146 …b5_make_principal (krb5_context context, krb5_principal * principal, krb5_const_realm realm, ...)" 156 \fIrealm\fP realm name 212 Compares the two principals, including realm of the principals and returns TRUE if they are the sam… 233 Return TRUE iff princ1 == princ2 (without considering the realm) [all …]
|
| /freebsd/crypto/heimdal/lib/krb5/ |
| H A D | principal.c | 39 * realm the principal belongs to and the former is a list of 0 or 64 #define princ_realm(P) ((P)->realm) 128 * Get the realm of the principal 131 * @param principal principal to get the realm for 133 * @return realm of the principal, don't free or use after krb5_principal is freed 194 heim_general_string realm = NULL; in krb5_parse_name_flags() local 214 N_("Can't require both realm and " in krb5_parse_name_flags() 215 "no realm at the same time", "")); in krb5_parse_name_flags() 279 N_("part after realm in principal name", "")); in krb5_parse_name_flags() 301 N_("part after realm in principal name", "")); in krb5_parse_name_flags() [all …]
|
| H A D | krbhst.c | 52 * `proto', `proto', `realm' using `dns_type'. 58 const char *realm, const char *dns_type, in srv_find_realm() argument 86 snprintf(domain, sizeof(domain), "_%s._%s.%s.", service, proto, realm); in srv_find_realm() 150 char *realm; member 195 return handle->realm; in _krb5_krbhst_get_realm() 447 ret = srv_find_realm(context, &res, &count, kd->realm, "SRV", proto, service, in srv_get_hosts() 449 _krb5_debug(context, 2, "searching DNS for realm %s %s.%s -> %d", in srv_get_hosts() 450 kd->realm, proto, service, ret); in srv_get_hosts() 470 "realms", kd->realm, conf_string, NULL); in config_get_hosts() 472 _krb5_debug(context, 2, "configuration file for realm %s%s found", in config_get_hosts() [all …]
|
| H A D | krb5_principal.3 | 93 .Fn krb5_princ_set_realm "krb5_context context" "krb5_principal principal" "krb5_realm *realm" 95 …ncipal "krb5_context context" "krb5_principal *principal" "int rlen" "krb5_const_realm realm" "..." 97 …"krb5_context context" "krb5_principal *principal" "int rlen" "krb5_const_realm realm" "va_list ap" 99 …l_ext" "krb5_context context" "krb5_principal *principal" "int rlen" "krb5_const_realm realm" "..." 101 …"krb5_context context" "krb5_principal *principal" "int rlen" "krb5_const_realm realm" "va_list ap" 103 .Fn krb5_make_principal "krb5_context context" "krb5_principal *principal" "krb5_const_realm realm"… 137 .Li realm . 158 requires the input string to be without a realm, and no realm is 163 requires the input string to with a realm. 181 no realm if the realm is one of the local realms. [all …]
|
| /freebsd/crypto/krb5/src/lib/krb5/os/ |
| H A D | hostrealm_dns.c | 35 * which uses TXT records in the DNS to determine the default realm or the 36 * fallback realm of a host. 46 * resulting realm (caller must free) or NULL. */ 50 char *realm; in txt_lookup() local 53 if (k5_try_realm_txt_rr(context, "_kerberos", fqdn, &realm) == 0) in txt_lookup() 54 return realm; in txt_lookup() 67 char *realm; in dns_fallback_realm() local 74 realm = txt_lookup(context, host); in dns_fallback_realm() 75 if (realm == NULL) in dns_fallback_realm() 77 ret = k5_make_realmlist(realm, realms_out); in dns_fallback_realm() [all …]
|
| /freebsd/crypto/heimdal/lib/kafs/ |
| H A D | common.c | 265 const char *cell, char **realm, int exact) in file_find_cell() argument 303 *realm = (*data->get_realm)(data, p); in file_find_cell() 304 if (*realm && **realm != '\0') in file_find_cell() 314 /* Find the realm associated with cell. Do this by opening CellServDB 315 file and getting the realm-of-host for the first VL-server for the 318 This does not work when the VL-server is living in one realm, but 319 the cell it is serving is living in another realm. 326 const char *cell, char **realm) in _kafs_realm_of_cell() argument 331 ret = file_find_cell(data, cell, realm, 1); in _kafs_realm_of_cell() 335 *realm = (*data->get_realm)(data, buf); in _kafs_realm_of_cell() [all …]
|
| /freebsd/crypto/heimdal/kadmin/ |
| H A D | check.c | 108 char *realm = NULL, *p, *p2; in check() local 112 ret = krb5_get_default_realm(context, &realm); in check() 118 realm = strdup(argv[0]); in check() 119 if (realm == NULL) { in check() 126 * Check krbtgt/REALM@REALM in check() 131 if (asprintf(&p, "%s/%s@%s", KRB5_TGS_NAME, realm, realm) == -1) { in check() 138 printf("%s doesn't exist, are you sure %s is a realm in your database", in check() 139 p, realm); in check() 148 * Check kadmin/admin@REALM in check() 151 if (asprintf(&p, "kadmin/admin@%s", realm) == -1) { in check() [all …]
|
| /freebsd/crypto/krb5/src/appl/sample/ |
| H A D | t_sample.py | 6 for realm in multipass_realms(create_host=False): 7 server_princ = 'sample/%s@%s' % (hostname, realm.realm) 8 realm.addprinc(server_princ) 9 realm.extract_keytab(server_princ, realm.keytab) 11 portstr = str(realm.server_port()) 12 server = realm.start_server([sserver, '-p', portstr], 'starting...') 13 out = realm.run([sclient, hostname, portstr], 17 server = realm.start_in_inetd([sserver]) 18 out = realm.run([sclient, hostname, portstr],
|