Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature: Select supported cards based on AID #39

Draft
wants to merge 7 commits into
base: main
Choose a base branch
from

Conversation

Muzosh
Copy link

@Muzosh Muzosh commented Dec 28, 2022

I have created this draft PR to layout very basic changes for Web-eID to be able to work with smartcards based on application AID installed on the card, not the ATR itself. Related to #38

@Muzosh Muzosh mentioned this pull request Dec 28, 2022
@Muzosh Muzosh changed the title Innitial commit (not working, syntax errors) Feature: Select supported cards based on AID Dec 28, 2022
@Muzosh
Copy link
Author

Muzosh commented Jan 4, 2023

Hi @mrts, I was wondering:

Instead of trying to list all AIDs located on the card (which I don't know if it's even possible), it might be easier to implement simple repeated SELECT + AID from hard-coded list of supported AIDs.
If the card returns SW 0x9000, the applet is located on the card and the Web-eID can claim this card to be supported.

Here's my question to your or anyone else working on the Web-eID (I do not have this knowledge or experience to know this):
Is this approach safe for the smart card integrity? Can a general smart card handle multiple repeated requests to select some applets? Is it possible, that with some huge "supported-AIDs" list defined in the Web-eID, it might somehow block the smart card by triggering some kind of brute-force protection?

Best Regards,
Petr.

@Muzosh
Copy link
Author

Muzosh commented Mar 6, 2023

STATUS UPDATE:
I'm not that experienced with modern C++ coding, but to my eye these changes seem OK. However, during simple testing, it managed to hog the memory of my mac very very fast, so there are definitely some issues in the code.

@@ -1,3 +1,3 @@
[submodule "lib/libpcsc-cpp"]
path = lib/libpcsc-cpp
url = ../libpcsc-cpp
url = https://github.com/web-eid/libpcsc-cpp
Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be reverted to the original relative path.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant