add a _DISPLAY_LABEL option in order to choose displaying ASN1 code or associated label - #16
add a _DISPLAY_LABEL option in order to choose displaying ASN1 code or associated label#16jbarotin wants to merge 1 commit into
Conversation
ASN1 code in order to string label for enum and choice type
|
Hello, |
|
Hello, I run test.py and it works.... but I have not set _DISPLAY_LABEL (my new options) to False. I think, that if I set _DISPLAY_LABEL to False, the re-encoding will not work. Do you think I have to adapt that ? (that's not usefull in my case). |
|
Yes, this actually breaks the re-encoding when decoding is done with PER._DISPLAY_LABEL set to False. There is several possibilities to make is work properly:
Best Regards, |
|
Hello, I need the ASN1 code not only for displaying purpose, but also to use these codes directly in the decoded object. So, I'm thinking of implementing the option number 3. The one you qualify of "less cleaner". Is that ok with you ? |
|
Yes ! Le jeudi 17 novembre 2016, Jérôme BAROTIN notifications@github.com a
|
Hi,
I needed to display ASN1 codes while decoding PER ASN1 data.
I provide you the code I change in your library in order to make that to work.
Best regards,
Jérôme