mirror of
https://github.com/chris2511/xca.git
synced 2026-09-12 19:51:05 +05:00
no message
This commit is contained in:
parent
cafc1cbec3
commit
e0c2f8bf29
@ -110,7 +110,7 @@ class MainWindow: public MainWindow_UI
|
||||
{
|
||||
Q_OBJECT
|
||||
protected:
|
||||
void addStr(std::std::string &str, const char *add);
|
||||
void addStr(std::string &str, const char *add);
|
||||
friend class pki_key;
|
||||
db_x509 *certs;
|
||||
db_x509req *reqs;
|
||||
@ -140,7 +140,7 @@ class MainWindow: public MainWindow_UI
|
||||
void insertReq(pki_x509req *req);
|
||||
void insertCert(pki_x509 *cert);
|
||||
void insertTemp(pki_temp *temp);
|
||||
std::std::string md5passwd();
|
||||
std::string md5passwd();
|
||||
bool opensslError(pki_base *pki);
|
||||
QPixmap *loadImg(const char *name);
|
||||
void renamePKI(db_base *db);
|
||||
|
||||
@ -83,9 +83,9 @@ void MainWindow::alterTemp()
|
||||
pki_temp *temp = (pki_temp *)temps->getSelectedPKI();
|
||||
if (!temp) return;
|
||||
MARK
|
||||
std::std::string oldname = temp->getDescription();
|
||||
std::string oldname = temp->getDescription();
|
||||
alterTemp(temp);
|
||||
std::std::string newname = temp->getDescription();
|
||||
std::string newname = temp->getDescription();
|
||||
if (newname!= oldname) {
|
||||
temp->setDescription(oldname);
|
||||
temps->renamePKI(temp, newname);
|
||||
@ -154,7 +154,7 @@ void MainWindow::showPopupTemp(QListViewItem *item, const QPoint &pt, int x) {
|
||||
void MainWindow::renameTemp(QListViewItem *item, int col, const QString &text)
|
||||
{
|
||||
pki_base *pki = temps->getSelectedPKI(item);
|
||||
std::std::string txt = text.latin1();
|
||||
std::string txt = text.latin1();
|
||||
temps->renamePKI(pki, txt);
|
||||
}
|
||||
|
||||
|
||||
@ -96,7 +96,7 @@ void MainWindow::newCert(NewX509 *dlg)
|
||||
int serial = 42; // :-)
|
||||
bool tempReq=false;
|
||||
int i, x, days;
|
||||
std::std::string cont="", subAltName="", issAltName="", constraints="",
|
||||
std::string cont="", subAltName="", issAltName="", constraints="",
|
||||
keyuse="", keyuse1="", pathstr="", certTypeStr = "";
|
||||
char *ekeyusage[]= {"serverAuth","clientAuth","codeSigning","emailProtection",
|
||||
"timeStamping","msCodeInd","msCodeCom",
|
||||
@ -113,14 +113,14 @@ void MainWindow::newCert(NewX509 *dlg)
|
||||
// Step 1 - Subject and key
|
||||
if (!dlg->fromReqCB->isChecked()) {
|
||||
clientkey = (pki_key *)keys->getSelectedPKI(dlg->keyList->currentText().latin1());
|
||||
std::std::string cn = dlg->commonName->text().latin1();
|
||||
std::std::string c = dlg->countryName->text().latin1();
|
||||
std::std::string l = dlg->localityName->text().latin1();
|
||||
std::std::string st = dlg->stateOrProvinceName->text().latin1();
|
||||
std::std::string o = dlg->organisationName->text().latin1();
|
||||
std::std::string ou = dlg->organisationalUnitName->text().latin1();
|
||||
std::std::string email = dlg->emailAddress->text().latin1();
|
||||
std::std::string desc = dlg->description->text().latin1();
|
||||
std::string cn = dlg->commonName->text().latin1();
|
||||
std::string c = dlg->countryName->text().latin1();
|
||||
std::string l = dlg->localityName->text().latin1();
|
||||
std::string st = dlg->stateOrProvinceName->text().latin1();
|
||||
std::string o = dlg->organisationName->text().latin1();
|
||||
std::string ou = dlg->organisationalUnitName->text().latin1();
|
||||
std::string email = dlg->emailAddress->text().latin1();
|
||||
std::string desc = dlg->description->text().latin1();
|
||||
tempReq = true;
|
||||
req = new pki_x509req(clientkey, cn,c,l,st,o,ou,email,desc,"");
|
||||
}
|
||||
@ -190,13 +190,13 @@ void MainWindow::newCert(NewX509 *dlg)
|
||||
cert->addV3ext(NID_basic_constraints, constraints);
|
||||
// Subject Key identifier
|
||||
if (dlg->subKey->isChecked()) {
|
||||
std::std::string subkey="hash";
|
||||
std::string subkey="hash";
|
||||
cert->addV3ext(NID_subject_key_identifier, subkey);
|
||||
CERR( subkey );
|
||||
}
|
||||
// Authority Key identifier
|
||||
if (dlg->authKey->isChecked()) {
|
||||
std::std::string authkey="keyid:always,issuer:always";
|
||||
std::string authkey="keyid:always,issuer:always";
|
||||
cert->addV3ext(NID_authority_key_identifier, authkey);
|
||||
CERR( authkey );
|
||||
}
|
||||
@ -314,9 +314,9 @@ void MainWindow::newCert(NewX509 *dlg)
|
||||
}
|
||||
|
||||
}
|
||||
void MainWindow::addStr(std::std::string &str, const char *add)
|
||||
void MainWindow::addStr(std::string &str, const char *add)
|
||||
{
|
||||
std::std::string sadd = add;
|
||||
std::string sadd = add;
|
||||
if (sadd.length() == 0) return;
|
||||
if (str.length() > 0 ) {
|
||||
str += ", ";
|
||||
@ -388,7 +388,7 @@ void MainWindow::showDetailsCert()
|
||||
|
||||
void MainWindow::showDetailsCert(QListViewItem *item)
|
||||
{
|
||||
std::std::string cert = item->text(0).latin1();
|
||||
std::string cert = item->text(0).latin1();
|
||||
showDetailsCert((pki_x509 *)certs->getSelectedPKI(cert));
|
||||
}
|
||||
|
||||
@ -433,8 +433,8 @@ bool MainWindow::showDetailsCert(pki_x509 *cert, bool import)
|
||||
dlg->serialNr->setText(cert->getSerial().c_str());
|
||||
|
||||
// details of subject
|
||||
std::std::string land = cert->getDNs(NID_countryName);
|
||||
std::std::string land1 = cert->getDNs(NID_stateOrProvinceName);
|
||||
std::string land = cert->getDNs(NID_countryName);
|
||||
std::string land1 = cert->getDNs(NID_stateOrProvinceName);
|
||||
if (land != "" && land1 != "")
|
||||
land += " / " +land1;
|
||||
else
|
||||
@ -471,7 +471,7 @@ bool MainWindow::showDetailsCert(pki_x509 *cert, bool import)
|
||||
dlg->dateValid->setText(tr("Not valid"));
|
||||
dlg->dateValid->setDisabled(true);
|
||||
}
|
||||
std::std::string revdate = cert->revokedAt();
|
||||
std::string revdate = cert->revokedAt();
|
||||
if (revdate != "") {
|
||||
dlg->dateValid->setText(tr("Revoked: ")+ revdate.c_str());
|
||||
dlg->dateValid->setDisabled(true);
|
||||
@ -492,7 +492,7 @@ bool MainWindow::showDetailsCert(pki_x509 *cert, bool import)
|
||||
|
||||
// show it to the user...
|
||||
if (dlg->exec()) {
|
||||
std::std::string ndesc = dlg->descr->text().latin1();
|
||||
std::string ndesc = dlg->descr->text().latin1();
|
||||
if (ndesc != cert->getDescription()) {
|
||||
certs->renamePKI(cert, ndesc);
|
||||
}
|
||||
@ -874,7 +874,7 @@ void MainWindow::renameCert(QListViewItem *item, int col, const QString &text)
|
||||
if (col != 0) return;
|
||||
try {
|
||||
pki_base *pki = certs->getSelectedPKI(item);
|
||||
std::std::string txt = text.latin1();
|
||||
std::string txt = text.latin1();
|
||||
certs->renamePKI(pki, txt);
|
||||
}
|
||||
catch (errorEx &err) {
|
||||
|
||||
14
xca.dsp
14
xca.dsp
@ -42,7 +42,7 @@ RSC=rc.exe
|
||||
# PROP Intermediate_Dir ""
|
||||
# PROP Ignore_Export_Lib 0
|
||||
# PROP Target_Dir ""
|
||||
# ADD CPP /nologo /MD /W3 /O1 /I "$(QTDIR)\include" /I "$(QTDIR)\mkspecs\win32-msvc" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "UNICODE" /D "QT_DLL" /D "QT_THREAD_SUPPORT" /D "QT_NO_DEBUG" /FD -Zm200 /c
|
||||
# ADD CPP /nologo /MD /W3 /O1 /I "$(QTDIR)\include" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_MBCS" /D "UNICODE" /D "QT_DLL" /D "QT_THREAD_SUPPORT" /D "QT_NO_DEBUG" /FD /I -Zm200 "$(QTDIR)\mkspecs\win32-msvc" /c
|
||||
# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
|
||||
# ADD BASE RSC /l 0x407
|
||||
# ADD RSC /l 0x409 /d "NDEBUG"
|
||||
@ -158,6 +158,10 @@ SOURCE=lib\pki_pkcs12.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\lib\pki_pkcs7.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=lib\pki_temp.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
@ -424,6 +428,10 @@ SOURCE=lib\pki_pkcs12.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\lib\pki_pkcs7.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=lib\pki_temp.h
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
@ -1103,6 +1111,10 @@ SOURCE=lib\moc_db_x509req.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\moc_ExportCert.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
SOURCE=.\moc_ExportCert_UI.cpp
|
||||
# End Source File
|
||||
# Begin Source File
|
||||
|
||||
Loading…
Reference in New Issue
Block a user