Author: jmagne
Update of /cvs/dirsec/esc/src/app/xpcom
In directory cvs1.fedora.phx.redhat.com:/tmp/cvs-serv28330
Modified Files:
CoolKeyCSP.cpp
Log Message:
Fix for Bug# 473982, publish certs to CAPI when enrolled token inserted.
Index: CoolKeyCSP.cpp
===================================================================
RCS file: /cvs/dirsec/esc/src/app/xpcom/CoolKeyCSP.cpp,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- CoolKeyCSP.cpp 25 Oct 2006 03:58:16 -0000 1.3
+++ CoolKeyCSP.cpp 29 Mar 2009 00:51:08 -0000 1.4
@@ -537,16 +537,19 @@
PR_LOG( coolKeyCSPLog, PR_LOG_DEBUG, ("CoolKeyCSPListener::RhNotifyStateChange
state %d \n",aKeyState));
AutoCoolKey key(aKeyType, aKeyID);
+ int enrolled = CoolKeyIsEnrolled(&key);
switch (aKeyState)
{
- //case eCKState_KeyInserted:
+ case eCKState_KeyInserted:
case eCKState_EnrollmentComplete:
- bOK = PropCerts(&key);
+ if( enrolled) {
+ bOK = PropCerts(&key);
+ }
break;
- //case eCKState_KeyRemoved:
+ case eCKState_KeyRemoved:
case eCKState_FormatComplete:
bOK = RemoveCerts(&key);