[Fedora-directory-commits] ldapserver/ldap/admin/src ds_viewlog.pl, 1.5, NONE
by Doctor Conrad
Author: nhosoi
Update of /cvs/dirsec/ldapserver/ldap/admin/src
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv1642
Removed Files:
ds_viewlog.pl
Log Message:
Resolves: #229576
Summary: clean up template-scriptname which is derived from template-scriptname.in (comment #3,4)
Description: removing obsolete scripts:
ds_viewlog.pl scripts/template-dsml-activate.pl
scripts/template-migrateInstance5 scripts/template-migrateTo6
scripts/template-migrate50to51
scripts/template-migrateInstance6 scripts/template-migrate5to6
scripts/template-migrateTo5
--- ds_viewlog.pl DELETED ---
15 years, 10 months
[Fedora-directory-commits] ldapserver/ldap/admin/src/scripts template-dsml-activate.pl, 1.7, NONE template-migrateInstance5, 1.5, NONE template-migrateTo6, 1.5, NONE template-migrate50to51, 1.6, NONE template-migrateInstance6, 1.5, NONE template-migrate5to6, 1.5, NONE template-migrateTo5, 1.6, NONE
by Doctor Conrad
Author: nhosoi
Update of /cvs/dirsec/ldapserver/ldap/admin/src/scripts
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv1642/scripts
Removed Files:
template-dsml-activate.pl template-migrateInstance5
template-migrateTo6 template-migrate50to51
template-migrateInstance6 template-migrate5to6
template-migrateTo5
Log Message:
Resolves: #229576
Summary: clean up template-scriptname which is derived from template-scriptname.in (comment #3,4)
Description: removing obsolete scripts:
ds_viewlog.pl scripts/template-dsml-activate.pl
scripts/template-migrateInstance5 scripts/template-migrateTo6
scripts/template-migrate50to51
scripts/template-migrateInstance6 scripts/template-migrate5to6
scripts/template-migrateTo5
--- template-dsml-activate.pl DELETED ---
--- template-migrateInstance5 DELETED ---
--- template-migrateTo6 DELETED ---
--- template-migrate50to51 DELETED ---
--- template-migrateInstance6 DELETED ---
--- template-migrate5to6 DELETED ---
--- template-migrateTo5 DELETED ---
15 years, 10 months
[Fedora-directory-commits] ldapserver/lib/libsi18n Makefile, 1.8, NONE
by Doctor Conrad
Author: nhosoi
Update of /cvs/dirsec/ldapserver/lib/libsi18n
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv607/lib/libsi18n
Removed Files:
Makefile
Log Message:
Resolves: #237040
Summary: Remove obsolete makefiles
Description: removing leftover makefiles in the lib directory
./lib/base/Makefile ./lib/libaccess/Makefile
./lib/libadmin/Makefile ./lib/libsi18n/Makefile
--- Makefile DELETED ---
15 years, 10 months
[Fedora-directory-commits] ldapserver/lib/libadmin Makefile, 1.11, NONE
by Doctor Conrad
Author: nhosoi
Update of /cvs/dirsec/ldapserver/lib/libadmin
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv607/lib/libadmin
Removed Files:
Makefile
Log Message:
Resolves: #237040
Summary: Remove obsolete makefiles
Description: removing leftover makefiles in the lib directory
./lib/base/Makefile ./lib/libaccess/Makefile
./lib/libadmin/Makefile ./lib/libsi18n/Makefile
--- Makefile DELETED ---
15 years, 10 months
[Fedora-directory-commits] ldapserver/lib/libaccess Makefile, 1.8, NONE
by Doctor Conrad
Author: nhosoi
Update of /cvs/dirsec/ldapserver/lib/libaccess
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv607/lib/libaccess
Removed Files:
Makefile
Log Message:
Resolves: #237040
Summary: Remove obsolete makefiles
Description: removing leftover makefiles in the lib directory
./lib/base/Makefile ./lib/libaccess/Makefile
./lib/libadmin/Makefile ./lib/libsi18n/Makefile
--- Makefile DELETED ---
15 years, 10 months
[Fedora-directory-commits] ldapserver/lib/base Makefile,1.8,NONE
by Doctor Conrad
Author: nhosoi
Update of /cvs/dirsec/ldapserver/lib/base
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv607/lib/base
Removed Files:
Makefile
Log Message:
Resolves: #237040
Summary: Remove obsolete makefiles
Description: removing leftover makefiles in the lib directory
./lib/base/Makefile ./lib/libaccess/Makefile
./lib/libadmin/Makefile ./lib/libsi18n/Makefile
--- Makefile DELETED ---
15 years, 10 months
[Fedora-directory-commits] ldapserver/ldap/servers/slapd util.c, 1.15, 1.16
by Doctor Conrad
Author: nhosoi
Update of /cvs/dirsec/ldapserver/ldap/servers/slapd
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv23306
Modified Files:
util.c
Log Message:
Resolves: #316281
Summary: db2bak fails if the archive path exists and ends with '/' (Comment #8)
Description: Changed the condition to normalize the path: if '.' or '/' is
included in the path, normalize it.
Index: util.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/util.c,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -r1.15 -r1.16
--- util.c 3 Oct 2007 00:55:35 -0000 1.15
+++ util.c 30 Nov 2007 17:23:13 -0000 1.16
@@ -529,8 +529,8 @@
}
}
retpath = slapi_ch_strdup(abspath);
- /* if there's no '.', no need to call normalize_path */
- if (NULL != strchr(abspath, '.') || NULL != strstr(abspath, _PSEP2))
+ /* if there's no '.' or separators, no need to call normalize_path */
+ if (NULL != strchr(abspath, '.') || NULL != strstr(abspath, _PSEP))
{
char **norm_path = normalize_path(abspath);
char **np, *rp;
15 years, 10 months
[Fedora-directory-commits] esc/src/app/xul/esc/chrome/content/esc ESC.js, 1.13.4.1, 1.13.4.2
by Doctor Conrad
Author: jmagne
Update of /cvs/dirsec/esc/src/app/xul/esc/chrome/content/esc
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv13790
Modified Files:
Tag: RHPKI_7_3_BRANCH
ESC.js
Log Message:
Actually check for the correct ATR for the special keys before using the global phone home preference, #Bug#352991.
Index: ESC.js
===================================================================
RCS file: /cvs/dirsec/esc/src/app/xul/esc/chrome/content/esc/ESC.js,v
retrieving revision 1.13.4.1
retrieving revision 1.13.4.2
diff -u -r1.13.4.1 -r1.13.4.2
--- ESC.js 19 Nov 2007 19:23:29 -0000 1.13.4.1
+++ ESC.js 29 Nov 2007 23:58:17 -0000 1.13.4.2
@@ -52,7 +52,7 @@
const ESC_SECURITY_URL="esc.security.url";
const ESC_SECURE_URL="esc.secure.url";
const ESC_GLOBAL_PHONE_HOME_URL= "esc.global.phone.home.url";
-const SPECIAL_ATR="3B769400FF6276010000";
+const SPECIAL_ATR="3B76940000FF6276010000";
const CLEAN_TOKEN = "cleanToken";
const UNINITIALIZED = 1;
@@ -258,6 +258,8 @@
recordMessage("Attempting phone home...");
+//alert("about to get IssuerUrl");
+
var home = DoCoolKeyGetIssuerUrl(keyType,keyID);
recordMessage("Returned IssuerURL " + home);
@@ -284,9 +286,9 @@
//Check for special key since we have no phone home info.
-
- home = GetGlobalPhoneHomeUrl(keyType,keyID);
-
+ if(!home) {
+ home = GetGlobalPhoneHomeUrl(keyType,keyID);
+ }
var homeRes = false;
@@ -325,26 +327,23 @@
var appletVerMaj = DoGetCoolKeyGetAppletVer(keyType, keyID , true);
var appletVerMin = DoGetCoolKeyGetAppletVer(keyType, keyID, false);
-
+
+
if( (appletVerMaj != specialAppletVerMaj) ||
- ( appletVerMin != specialAppletVerMin)) {
+ ( appletVerMin > specialAppletVerMin)) {
return null;
}
var keyATR = DoCoolKeyGetATR(keyType,keyID);
- if( keyATR != specialATR) {
+ if( keyATR != specialATR) {
return null;
-
}
globalIssuerURL = DoCoolKeyGetConfigValue(ESC_GLOBAL_PHONE_HOME_URL);
- if(globalIssuerURL==null) {
- return null;
- }
return globalIssuerURL;
@@ -3386,12 +3385,18 @@
function DoCoolKeyGetIssuerUrl(keyType,keyID)
{
var url = null;
+ var isMac = 0;
+ var agent = navigator.userAgent.toLowerCase();
//Back door for testing, ignore the value if so configured
+ if(agent && agent.indexOf("mac") != -1) {
+ isMac = 1;
+ }
+
var ignoreIssuer = DoCoolKeyGetConfigValue(ESC_IGNORE_KEY_ISSUER_INFO);
- recordMessage("DoCoolKeyGetIssuerUrl ignoreIssuer: " + ignoreIssuer);
+ recordMessage("DoCoolKeyGetIssuerUrl agent " + agent);
if(ignoreIssuer == "yes")
{
@@ -3403,15 +3408,19 @@
netscape.security.PrivilegeManager.enablePrivilege("UniversalXPConnect");
var tries = 0;
- while(tries < 3)
+ while(tries < 3 )
{
url = netkey.GetCoolKeyIssuerInfo(keyType, keyID);
- if(url.length < 10) // Check for bogus junk
+ if(!isMac) {
+ break;
+ }
+
+ if(!url || url.length < 10) // Check for bogus junk
{
recordMessage("Bogus url found ....");
url = null;
- Sleep(150);
+ Sleep(250);
recordMessage("Going to try again... ");
}
else
@@ -3434,11 +3443,14 @@
{
url = netkey.GetCoolKeyIssuerInfo(keyType, keyID);
- if(url.length < 10) // Check for bogus junk
+ if(!isMac) {
+ break;
+ }
+ if(!url || url.length < 10) // Check for bogus junk
{
recordMessage("Bogus url found from exception....");
url = null;
- sleep(150);
+ sleep(250);
recordMessage("From exception. Going to try again... ");
}
else
@@ -3446,6 +3458,11 @@
tries ++;
}
+ if(url)
+ {
+ var issuer_config_value_exp = ConfigValueWithKeyID(keyID,KEY_ISSUER_URL);
+ var result_exp = DoCoolKeySetConfigValue(issuer_config_value_exp,url);
+ }
recordMessage("From exception returning " + url);
return url;
}
15 years, 10 months
[Fedora-directory-commits] mod_admserv mod_admserv.c,1.32,1.33
by Doctor Conrad
Author: nkinder
Update of /cvs/dirsec/mod_admserv
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv11357
Modified Files:
mod_admserv.c
Log Message:
Resolves: 400341
Summary: Be sure to only change admin user's password in change-sie-password.
Index: mod_admserv.c
===================================================================
RCS file: /cvs/dirsec/mod_admserv/mod_admserv.c,v
retrieving revision 1.32
retrieving revision 1.33
diff -u -r1.32 -r1.33
--- mod_admserv.c 6 Jul 2007 18:06:19 -0000 1.32
+++ mod_admserv.c 29 Nov 2007 23:22:18 -0000 1.33
@@ -701,6 +701,9 @@
return admserv_ldap_auth_userdn_password(server, data->bindDN, data->bindPW, &ignored);
}
+/* The returned string is allocated from a pool in APR. Attempting to free this string
+ * will result in a crash. APR will deal with the cleanup itself when it cleans up the
+ * entire pool. */
static char *
formLdapURL(LdapServerData *data, apr_pool_t *p)
{
@@ -1196,19 +1199,44 @@
const char* bindpw, request_rec *r)
{
LDAP *ld;
+ AdmldapInfo ldapInfo;
int ldapError;
char *ldapURL = NULL;
const char *userDN = NULL;
+ char *adminDN = NULL;
LDAPMod mod, *mods[2];
char *vals[2];
char *attrs[2];
int rval = 0;
+ int error;
- /* update password for uid */
+ /* We need ldapInfo to fetch the adminDN */
+ ap_log_error(APLOG_MARK, APLOG_DEBUG, 0, NULL,
+ "task_update_registry_server_bindpw: getting ldap info for [%s]",
+ configdir);
+ ldapInfo = admldapBuildInfo(configdir, &error);
+
+ if (!ldapInfo) {
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, NULL,
+ "task_update_registry_server_bindpw: Could not build ldap info for config in [%s]: %d",
+ configdir, error);
+ goto bailout;
+ }
+
+ /* get the admin user DN */
+ adminDN = admldapGetUserDN(ldapInfo, NULL);
+
+ if (!adminDN) {
+ ap_log_error(APLOG_MARK, APLOG_ERR, 0, NULL,
+ "failed to retreive admin user DN");
+ goto bailout;
+ }
+
+ /* update password for adminDN */
if (!(ld = openLDAPConnection(®istryServer))) {
ap_log_error(APLOG_MARK, APLOG_ERR, 0, NULL,
"task_update_registry_server_bindpw(): cannot connect to the Configuration Directory Server");
- return rval;
+ goto bailout;
}
userDN = apr_table_get(r->notes, RQ_NOTES_USERDN);
@@ -1246,21 +1274,33 @@
mod.mod_values = vals;
mods[0] = &mod;
mods[1] = NULL;
- if (LDAP_SUCCESS != (ldapError = ldap_modify_s(ld, userDN, mods))) {
+ if (LDAP_SUCCESS != (ldapError = ldap_modify_s(ld, adminDN, mods))) {
ap_log_error(APLOG_MARK, APLOG_ERR, 0, NULL,
"task_update_registry_server_bindpw(): ldap_modify for %s failed: %s",
- userDN, ldap_err2string(ldapError));
+ adminDN, ldap_err2string(ldapError));
goto bailout;
}
- /* update the auth_users cache */
+
+ /* we don't want to free this since APR allocates it from a pool. APR will take care of it */
ldapURL = formLdapURL(®istryServer, r->pool);
- create_auth_users_cache_entry(uid, (char *)userDN, password, ldapURL);
+
+ /* update the auth_users cache */
+ create_auth_users_cache_entry(uid, adminDN, password, ldapURL);
+
+ /* We only want to reset the pwd in the request if RQ_NOTES_USERDN is the admin user */
+ if(strcasecmp(adminDN, userDN) == 0) {
+ apr_table_set(r->notes, RQ_NOTES_USERPW, password);
+ }
rval = 1;
+
bailout:
- closeLDAPConnection(ld);
- if (NULL != ldapURL)
- free(ldapURL);
+ if (ld) {
+ closeLDAPConnection(ld);
+ }
+ if (ldapInfo) {
+ destroyAdmldap(ldapInfo);
+ }
return rval;
}
@@ -1271,12 +1311,12 @@
change_sie_password(const char *name, char *query, void* arg, request_rec *r)
{
FILE *f;
- char *uid=NULL ,*pw=NULL, *col=NULL;
+ char *uid=NULL ,*pw=NULL, *col=NULL, *origpw_hash=NULL;
char *newpw=query;
char filename[BIG_LINE];
char inbuf[BIG_LINE];
char outbuf[64]; /* needs at least 36 bytes */
- char *origpw = (char *)apr_table_get(r->notes, RQ_NOTES_USERPW);
+ char *bindpw = (char *)apr_table_get(r->notes, RQ_NOTES_USERPW);
int admpwd_done = 0;
apr_snprintf(filename, sizeof(filename), "%s/admpw", configdir);
@@ -1307,7 +1347,7 @@
return 0;
}
- uid = inbuf; *col=0; pw=col+1;
+ uid = inbuf; *col=0; origpw_hash=col+1;
apr_sha1_base64(newpw, strlen(newpw), outbuf);
if (!update_admpwd(configdir, uid, outbuf)) {
@@ -1317,18 +1357,17 @@
}
admpwd_done = 1;
- if (!task_update_registry_server_bindpw(uid, strdup(newpw), origpw, r)) {
+ if (!task_update_registry_server_bindpw(uid, strdup(newpw), bindpw, r)) {
ap_log_error(APLOG_MARK, APLOG_ERR, 0, NULL,
"failed to update server bindpw");
goto recover;
}
- apr_table_set(r->notes, RQ_NOTES_USERPW, newpw);
+
return 1;
recover:
if (admpwd_done) {
- apr_sha1_base64(origpw, strlen(origpw), outbuf);
- update_admpwd(configdir, uid, outbuf);
+ update_admpwd(configdir, uid, origpw_hash);
}
return 0;
}
15 years, 10 months
[Fedora-directory-commits] ldapserver/ldap/servers/slapd/back-ldbm ldbm_config.c, 1.12, 1.13
by Doctor Conrad
Author: nhosoi
Update of /cvs/dirsec/ldapserver/ldap/servers/slapd/back-ldbm
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv16565
Modified Files:
ldbm_config.c
Log Message:
Resolves: #238649
Summary: Hide nsslapd-db-transaction
Description: don't show the configuration parameter nsslapd-db-transaction in
dse.ldif.
Index: ldbm_config.c
===================================================================
RCS file: /cvs/dirsec/ldapserver/ldap/servers/slapd/back-ldbm/ldbm_config.c,v
retrieving revision 1.12
retrieving revision 1.13
diff -u -r1.12 -r1.13
--- ldbm_config.c 14 Nov 2007 15:04:51 -0000 1.12
+++ ldbm_config.c 28 Nov 2007 19:03:42 -0000 1.13
@@ -1202,7 +1202,7 @@
{CONFIG_DB_LOGDIRECTORY, CONFIG_TYPE_STRING, "", &ldbm_config_db_logdirectory_get, &ldbm_config_db_logdirectory_set, CONFIG_FLAG_ALWAYS_SHOW},
{CONFIG_DB_DURABLE_TRANSACTIONS, CONFIG_TYPE_ONOFF, "on", &ldbm_config_db_durable_transactions_get, &ldbm_config_db_durable_transactions_set, CONFIG_FLAG_ALWAYS_SHOW},
{CONFIG_DB_CIRCULAR_LOGGING, CONFIG_TYPE_ONOFF, "on", &ldbm_config_db_circular_logging_get, &ldbm_config_db_circular_logging_set, 0},
- {CONFIG_DB_TRANSACTION_LOGGING, CONFIG_TYPE_ONOFF, "on", &ldbm_config_db_transaction_logging_get, &ldbm_config_db_transaction_logging_set, CONFIG_FLAG_ALWAYS_SHOW},
+ {CONFIG_DB_TRANSACTION_LOGGING, CONFIG_TYPE_ONOFF, "on", &ldbm_config_db_transaction_logging_get, &ldbm_config_db_transaction_logging_set, 0},
{CONFIG_DB_CHECKPOINT_INTERVAL, CONFIG_TYPE_INT, "60", &ldbm_config_db_checkpoint_interval_get, &ldbm_config_db_checkpoint_interval_set, CONFIG_FLAG_ALWAYS_SHOW|CONFIG_FLAG_ALLOW_RUNNING_CHANGE},
{CONFIG_DB_TRANSACTION_BATCH, CONFIG_TYPE_INT, "0", &dblayer_get_batch_transactions, &dblayer_set_batch_transactions, CONFIG_FLAG_ALWAYS_SHOW|CONFIG_FLAG_ALLOW_RUNNING_CHANGE},
{CONFIG_DB_LOGBUF_SIZE, CONFIG_TYPE_SIZE_T, "0", &ldbm_config_db_logbuf_size_get, &ldbm_config_db_logbuf_size_set, CONFIG_FLAG_ALWAYS_SHOW},
15 years, 10 months