]> git.zerfleddert.de Git - proxmark3-svn/blobdiff - client/emv/emv_tags.c
tlv decoder works.
[proxmark3-svn] / client / emv / emv_tags.c
index 9bcf20043cfa4a7e890d98e50c6de56f024794ee..1aae847af2f668d17b4ba98326e2342c0cc4f4ca 100644 (file)
@@ -30,7 +30,6 @@ enum emv_tag_t {
        EMV_TAG_STRING,
        EMV_TAG_NUMERIC,
        EMV_TAG_YYMMDD,
-       EMV_TAG_FCI,
 };
 
 struct emv_tag {
@@ -128,7 +127,7 @@ static const struct emv_tag emv_tags[] = {
        { 0x5f30, "Service Code", EMV_TAG_NUMERIC },
        { 0x5f34, "Application Primary Account Number (PAN) Sequence Number", EMV_TAG_NUMERIC },
        { 0x61  , "Application Template" },
-       { 0x6f  , "File Control Information (FCI) Template", EMV_TAG_FCI },
+       { 0x6f  , "File Control Information (FCI) Template" },
        { 0x70  , "READ RECORD Response Message Template" },
        { 0x77  , "Response Message Template Format 2" },
        { 0x80  , "Response Message Template Format 1" },
@@ -269,25 +268,6 @@ static void emv_tag_dump_dol(const struct tlv *tlv, const struct emv_tag *tag, F
        }
 }
 
-static void emv_tag_dump_fci(const struct tlv *tlv, const struct emv_tag *tag, FILE *f) {
-       const unsigned char *buf = tlv->value;
-       size_t left = tlv->len;
-
-       while (left) {
-               struct tlv doltlv;
-               const struct emv_tag *doltag;
-
-               if (!tlv_parse_tl(&buf, &left, &doltlv)) {
-                       fprintf(f, "Invalid Tag-Len\n");
-                       continue;
-               }
-
-               doltag = emv_get_tag(&doltlv);
-
-               fprintf(f, "\t--%2hx[%02zx]'%s'\n", doltlv.tag, doltlv.len, doltag->name);
-       }
-}
-
 static void emv_tag_dump_string(const struct tlv *tlv, const struct emv_tag *tag, FILE *f)
 {
        fprintf(f, "\tString value '");
@@ -471,9 +451,6 @@ bool emv_tag_dump(const struct tlv *tlv, FILE *f)
        case EMV_TAG_YYMMDD:
                emv_tag_dump_yymmdd(tlv, tag, f);
                break;
-       case EMV_TAG_FCI:
-               emv_tag_dump_fci(tlv, tag, f);
-               break;
        };
 
        return true;
Impressum, Datenschutz