Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
PIM
Kleopatra
Commits
011e71ff
Commit
011e71ff
authored
May 18, 2021
by
Ingo Klöcker
Browse files
Remove now superfluous P15Card::appKeyFingerprint()
GnuPG-bug-id: 4876
parent
21957820
Pipeline
#62376
canceled with stage
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
src/smartcard/p15card.cpp
View file @
011e71ff
...
...
@@ -9,9 +9,6 @@
#include "p15card.h"
#include "kleopatra_debug.h"
using
namespace
Kleo
;
using
namespace
Kleo
::
SmartCard
;
// static
...
...
@@ -22,8 +19,3 @@ P15Card::P15Card(const Card &card)
{
setAppName
(
AppName
);
}
std
::
string
P15Card
::
appKeyFingerprint
(
const
std
::
string
&
appKeyRef
)
const
{
return
cardInfo
(
"KLEO-FPR-"
+
appKeyRef
);
}
src/smartcard/p15card.h
View file @
011e71ff
...
...
@@ -14,6 +14,7 @@ namespace Kleo
{
namespace
SmartCard
{
/** Class to work with PKCS#15 smartcards or compatible tokens.
*
* A PKCS#15 card is pretty generic and there is no real standard
...
...
@@ -30,13 +31,7 @@ public:
explicit
P15Card
(
const
Card
&
card
);
static
const
std
::
string
AppName
;
/* Obtain an application specific fingerprint for a key
* stored on this card.
* e.g. An App Key Ref would be
* OpenPGPCard::pgpSigKeyRef */
std
::
string
appKeyFingerprint
(
const
std
::
string
&
appKeyRef
)
const
;
};
}
// namespace Smartcard
}
// namespace Kleopatra
}
}
src/view/p15cardwidget.cpp
View file @
011e71ff
...
...
@@ -184,7 +184,7 @@ void P15CardWidget::setCard(const P15Card *card)
const
auto
key
=
KeyCache
::
instance
()
->
findSubkeyByKeyGrip
(
sigInfo
.
grip
,
GpgME
::
OpenPGP
).
parent
();
if
(
key
.
isNull
())
{
qCDebug
(
KLEOPATRA_LOG
)
<<
"Failed to find key for grip:"
<<
sigInfo
.
grip
.
c_str
();
const
auto
pgpSigFpr
=
card
->
appK
eyFingerprint
(
OpenPGPCard
::
pgpSigKeyRef
());
const
auto
pgpSigFpr
=
card
->
k
eyFingerprint
(
OpenPGPCard
::
pgpSigKeyRef
());
if
(
!
pgpSigFpr
.
empty
())
{
qCDebug
(
KLEOPATRA_LOG
)
<<
"Should be pgp key:"
<<
pgpSigFpr
.
c_str
();
searchPGPFpr
(
pgpSigFpr
);
...
...
@@ -194,9 +194,9 @@ void P15CardWidget::setCard(const P15Card *card)
}
}
std
::
string
keyid
=
card
->
appK
eyFingerprint
(
OpenPGPCard
::
pgpSigKeyRef
());
std
::
string
keyid
=
card
->
k
eyFingerprint
(
OpenPGPCard
::
pgpSigKeyRef
());
updateSigKeyWidgets
(
keyid
);
keyid
=
card
->
appK
eyFingerprint
(
OpenPGPCard
::
pgpEncKeyRef
());
keyid
=
card
->
k
eyFingerprint
(
OpenPGPCard
::
pgpEncKeyRef
());
if
(
!
keyid
.
empty
())
{
mEncFprLabel
->
setText
(
i18n
(
"Encryption key:"
)
+
QStringLiteral
(
" %1 (%2)"
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment