aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--sm/ChangeLog3
-rw-r--r--sm/certchain.c9
-rw-r--r--sm/certpath.c9
3 files changed, 17 insertions, 4 deletions
diff --git a/sm/ChangeLog b/sm/ChangeLog
index e44044b16..ac45cfa55 100644
--- a/sm/ChangeLog
+++ b/sm/ChangeLog
@@ -1,5 +1,8 @@
2002-07-02 Werner Koch <[email protected]>
+ * certpath.c (check_cert_policy): Don't use log_error to print a
+ warning.
+
* keydb.c (keydb_store_cert): Add optional ar EXISTED and changed
all callers.
* call-agent.c (learn_cb): Print info message only for real imports.
diff --git a/sm/certchain.c b/sm/certchain.c
index 719f97b61..39fd0adfd 100644
--- a/sm/certchain.c
+++ b/sm/certchain.c
@@ -145,9 +145,14 @@ check_cert_policy (KsbaCert cert)
if (feof (fp))
{
fclose (fp);
- log_error (_("certificate policy not allowed\n"));
/* with no critical policies this is only a warning */
- return any_critical? GNUPG_No_Policy_Match : 0;
+ if (!any_critical)
+ {
+ log_info (_("note: certificate policy not allowed\n"));
+ return 0;
+ }
+ log_error (_("certificate policy not allowed\n"));
+ return GNUPG_No_Policy_Match;
}
fclose (fp);
return GNUPG_Read_Error;
diff --git a/sm/certpath.c b/sm/certpath.c
index 719f97b61..39fd0adfd 100644
--- a/sm/certpath.c
+++ b/sm/certpath.c
@@ -145,9 +145,14 @@ check_cert_policy (KsbaCert cert)
if (feof (fp))
{
fclose (fp);
- log_error (_("certificate policy not allowed\n"));
/* with no critical policies this is only a warning */
- return any_critical? GNUPG_No_Policy_Match : 0;
+ if (!any_critical)
+ {
+ log_info (_("note: certificate policy not allowed\n"));
+ return 0;
+ }
+ log_error (_("certificate policy not allowed\n"));
+ return GNUPG_No_Policy_Match;
}
fclose (fp);
return GNUPG_Read_Error;