Restconf: Support for list of media in Accept:
Restconf: Better RFC compliance with Accept errors: 406 vs 415 Fixed: [RESTCONF exit on cert error + complex accept](https://github.com/clicon/clixon/issues/551)
This commit is contained in:
parent
19c11eabb7
commit
c1ea72bcb3
14 changed files with 173 additions and 80 deletions
|
|
@ -55,6 +55,7 @@ enum restconf_media{
|
|||
YANG_PATCH_JSON, /* "application/yang-patch+json" */
|
||||
YANG_PATCH_XML, /* "application/yang-patch+xml" */
|
||||
YANG_PAGINATION_XML, /* draft-wwlh-netconf-list-pagination-rc-02.txt */
|
||||
HTTP_DATA_TEXT_HTML /* For http_data */
|
||||
};
|
||||
typedef enum restconf_media restconf_media;
|
||||
|
||||
|
|
@ -84,6 +85,8 @@ typedef enum restconf_http_proto restconf_http_proto;
|
|||
int restconf_err2code(char *tag);
|
||||
const char *restconf_code2reason(int code);
|
||||
const restconf_media restconf_media_str2int(char *media);
|
||||
int restconf_media_in_list(char *media, char *list);
|
||||
const restconf_media restconf_media_list_str2int(char *list);
|
||||
const char *restconf_media_int2str(restconf_media media);
|
||||
int restconf_str2proto(char *str);
|
||||
const char *restconf_proto2str(int proto);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue