]>
git.zerfleddert.de Git - proxmark3-svn/blob - client/emv/emvjson.h
996b611d5dfd7a32cc81f98cd6d80b588db34296
1 //-----------------------------------------------------------------------------
2 // Copyright (C) 2018 Merlok
4 // This code is licensed to you under the terms of the GNU GPL, version 2 or,
5 // at your option, any later version. See the LICENSE.txt file for the text of
7 //-----------------------------------------------------------------------------
9 //-----------------------------------------------------------------------------
21 extern char* GetApplicationDataName(tlv_tag_t tag
);
23 extern int JsonSaveJsonObject(json_t
*root
, char *path
, json_t
*value
);
24 extern int JsonSaveStr(json_t
*root
, char *path
, char *value
);
25 extern int JsonSaveInt(json_t
*root
, char *path
, int value
);
26 extern int JsonSaveBufAsHexCompact(json_t
*elm
, char *path
, uint8_t *data
, size_t datalen
);
27 extern int JsonSaveBufAsHex(json_t
*elm
, char *path
, uint8_t *data
, size_t datalen
);
28 extern int JsonSaveHex(json_t
*elm
, char *path
, uint64_t data
, int datalen
);
30 extern int JsonSaveTLVValue(json_t
*root
, char *path
, struct tlvdb
*tlvdbelm
);
31 extern int JsonSaveTLVElm(json_t
*elm
, char *path
, struct tlv
*tlvelm
, bool saveName
, bool saveValue
, bool saveAppDataLink
);
32 extern int JsonSaveTLVTreeElm(json_t
*elm
, char *path
, struct tlvdb
*tlvdbelm
, bool saveName
, bool saveValue
, bool saveAppDataLink
);
34 extern int JsonSaveTLVTree(json_t
*root
, json_t
*elm
, char *path
, struct tlvdb
*tlvdbelm
);
36 extern int JsonLoadStr(json_t
*root
, char *path
, char *value
);
37 extern int JsonLoadBufAsHex(json_t
*elm
, char *path
, uint8_t *data
, size_t maxbufferlen
, size_t *datalen
);
39 extern bool ParamLoadFromJson(struct tlvdb
*tlv
);