eclipse-keyple / keyple-java-example

Eclipse Keyple™ Project: use case examples of the Keyple Java components for end users
https://keyple.org
Eclipse Public License 2.0
7 stars 4 forks source link

Stub example with Keyple version 2 #4

Closed BhushanPatil555 closed 2 years ago

BhushanPatil555 commented 2 years ago

Hi, As mentioned in the readme, the stub implementation under Example_Card_Calypso/ is called [Main_ExplicitSelectionAid_Stub.java], which I am not able to locate in git repo. I assume this might be under implementation or is there any other link.

Provide support for this.

Regards Bhushan

jeanpierrefortune commented 2 years ago

Hi Bhushan,

Thank you for pointing this out. Indeed we have not yet migrated the Stub examples with Keyple 2.0.

However the use of these examples is very limited and their purpose is only to allow Keyple to work without a physical reader.

We'll probably limit ourselves to a single Stub example for Keyple 2.0 in the coming weeks.

That said, feel free to let us know if you have any difficulties implementing Keyple with a real reader.

Regards,

Jean-Pierre

BhushanPatil555 commented 2 years ago

Hello Jean,

Thank you very much for prompt reply.

For time being, I do not have any trouble with Keyple 2.0 with real readers( PCSC) examples from GIT. They work fine.

What I looking is to have a combination of a real reader and a stub.

I am planning to use a real reader where I place my card and use stub reader to simulate the SAM.

I tried to implement on my own using the API documentation but was not successful hence posted the query.

If you can help me in this aspect would be really useful.

Thanks in advance. Regards Bhushan

pterr commented 2 years ago

Hello Bhushan, Thanks for your feedback, I just realize that when reorganizing the repositories for the last release 2.0 of Keyple Java, many examples of the stub plugin are now missing.

The stub plugin is just a tool that allows running the Keyple Service API without having any reader. In the past we also did stub examples using the Calypso card extension: for that, we had to provide Calypso card stub image and Calypso SAM stub image. These stub images were very "light" emulation of Calypso card and Calypso SAM => of course the cryptographic processing was fake. So using a Calypso card stub image and a Calypso SAM stub image, it was possible to operate a Calypso secure session but the authentication result was fake. It isn't possible to mix a Calypso card stub image with a real Calypso SAM, or to mix a real Calypso card with a Calypso SAM stub image. To operate a real Calypso card you need also a real Calypso SAM.

We will again add the Calypso card & SAM stub images' examples in https://github.com/eclipse/keyple-java-example

If you need samples of Calypso cards or SAM, you can purchase a test with the Calypso Networks Association:

BhushanPatil555 commented 2 years ago

Hello Pierre, Good Morning

Thanks for clarification.

We will place an order to get Calypso SAM.

Regards, Bhushan

jeanpierrefortune commented 2 years ago

Hello Bhushan,

In case it is of any use to you, we have updated three examples showing the use of the Stub plugin in the Calypso context (See PR #8).

Regards, Jean-Pierre