|
Lines 13-20
Link Here
|
| 13 |
|
13 |
|
| 14 |
#include <ksslcertificate.h> |
14 |
#include <ksslcertificate.h> |
| 15 |
|
15 |
|
|
|
16 |
#ifdef __TDE_HAVE_TDEHWLIB |
| 16 |
#include <tdehardwaredevices.h> |
17 |
#include <tdehardwaredevices.h> |
| 17 |
#include <tdecryptographiccarddevice.h> |
18 |
#include <tdecryptographiccarddevice.h> |
|
|
19 |
#endif |
| 18 |
|
20 |
|
| 19 |
#include <kstandarddirs.h> |
21 |
#include <kstandarddirs.h> |
| 20 |
#include <tdeapplication.h> |
22 |
#include <tdeapplication.h> |
|
Lines 166-171
SaverEngine::SaverEngine()
Link Here
|
| 166 |
pthread_sigmask(SIG_BLOCK, &mThreadBlockSet, NULL); |
168 |
pthread_sigmask(SIG_BLOCK, &mThreadBlockSet, NULL); |
| 167 |
|
169 |
|
| 168 |
// Initialize SmartCard readers |
170 |
// Initialize SmartCard readers |
|
|
171 |
#ifdef __TDE_HAVE_TDEHWLIB |
| 169 |
TDEGenericDevice *hwdevice; |
172 |
TDEGenericDevice *hwdevice; |
| 170 |
TDEHardwareDevices *hwdevices = TDEGlobal::hardwareDevices(); |
173 |
TDEHardwareDevices *hwdevices = TDEGlobal::hardwareDevices(); |
| 171 |
TDEGenericHardwareList cardReaderList = hwdevices->listByDeviceClass(TDEGenericDeviceType::CryptographicCard); |
174 |
TDEGenericHardwareList cardReaderList = hwdevices->listByDeviceClass(TDEGenericDeviceType::CryptographicCard); |
|
Lines 175-180
SaverEngine::SaverEngine()
Link Here
|
| 175 |
connect(cdevice, TQT_SIGNAL(cardRemoved(TDECryptographicCardDevice*)), this, TQT_SLOT(cryptographicCardRemoved(TDECryptographicCardDevice*))); |
178 |
connect(cdevice, TQT_SIGNAL(cardRemoved(TDECryptographicCardDevice*)), this, TQT_SLOT(cryptographicCardRemoved(TDECryptographicCardDevice*))); |
| 176 |
cdevice->enableCardMonitoring(true); |
179 |
cdevice->enableCardMonitoring(true); |
| 177 |
} |
180 |
} |
|
|
181 |
#endif |
| 178 |
|
182 |
|
| 179 |
// Check card login status |
183 |
// Check card login status |
| 180 |
KUser userinfo; |
184 |
KUser userinfo; |
|
Lines 229-234
void SaverEngine::cardStartupTimeout() {
Link Here
|
| 229 |
|
233 |
|
| 230 |
void SaverEngine::cryptographicCardInserted(TDECryptographicCardDevice* cdevice) { |
234 |
void SaverEngine::cryptographicCardInserted(TDECryptographicCardDevice* cdevice) { |
| 231 |
TQString login_name = TQString::null; |
235 |
TQString login_name = TQString::null; |
|
|
236 |
#ifdef __TDE_HAVE_TDEHWLIB |
| 232 |
X509CertificatePtrList certList = cdevice->cardX509Certificates(); |
237 |
X509CertificatePtrList certList = cdevice->cardX509Certificates(); |
| 233 |
if (certList.count() > 0) { |
238 |
if (certList.count() > 0) { |
| 234 |
KSSLCertificate* card_cert = NULL; |
239 |
KSSLCertificate* card_cert = NULL; |
|
Lines 249-254
void SaverEngine::cryptographicCardInserted(TDECryptographicCardDevice* cdevice)
Link Here
|
| 249 |
mValidCryptoCardInserted = true; |
254 |
mValidCryptoCardInserted = true; |
| 250 |
} |
255 |
} |
| 251 |
} |
256 |
} |
|
|
257 |
#endif |
| 252 |
} |
258 |
} |
| 253 |
|
259 |
|
| 254 |
void SaverEngine::cryptographicCardRemoved(TDECryptographicCardDevice* cdevice) { |
260 |
void SaverEngine::cryptographicCardRemoved(TDECryptographicCardDevice* cdevice) { |