diff options
| author | Philippe Guibert <philippe.guibert@6wind.com> | 2018-03-07 18:54:09 +0100 | 
|---|---|---|
| committer | Philippe Guibert <philippe.guibert@6wind.com> | 2018-03-30 14:01:06 +0200 | 
| commit | d33fc23bf8d70bea0fabae541e127b4bdbc77a8d (patch) | |
| tree | c482a09efcd7903df5d8a7f283dd08cf42d0a707 /bgpd/bgp_flowspec.h | |
| parent | e7d78d0f2ceab5d0c078961d0377265ddecf5e43 (diff) | |
bgpd: support for json in show bgp ipv4 flowspec commands
The json format is returd when requested from the two commands:
- show bgp ipv4 flowspec
- show bgp ipv4 flowspec detail
Signed-off-by: Philippe Guibert <philippe.guibert@6wind.com>
Diffstat (limited to 'bgpd/bgp_flowspec.h')
| -rw-r--r-- | bgpd/bgp_flowspec.h | 11 | 
1 files changed, 7 insertions, 4 deletions
diff --git a/bgpd/bgp_flowspec.h b/bgpd/bgp_flowspec.h index 791ed2e693..392b321530 100644 --- a/bgpd/bgp_flowspec.h +++ b/bgpd/bgp_flowspec.h @@ -19,9 +19,11 @@  #ifndef _FRR_BGP_FLOWSPEC_H  #define _FRR_BGP_FLOWSPEC_H -#define NLRI_STRING_FORMAT_LARGE 0 -#define NLRI_STRING_FORMAT_DEBUG 1 -#define NLRI_STRING_FORMAT_MIN   2 +#define NLRI_STRING_FORMAT_LARGE        0 +#define NLRI_STRING_FORMAT_DEBUG        1 +#define NLRI_STRING_FORMAT_MIN          2 +#define NLRI_STRING_FORMAT_JSON         3 +#define NLRI_STRING_FORMAT_JSON_SIMPLE  4  #define BGP_FLOWSPEC_NLRI_STRING_MAX 512 @@ -39,7 +41,8 @@ extern int bgp_show_table_flowspec(struct vty *vty, struct bgp *bgp, afi_t afi,  				   unsigned long *total_cum);  extern void bgp_fs_nlri_get_string(unsigned char *nlri_content, size_t len, -				    char *return_string, int format); +				   char *return_string, int format, +				   json_object *json_path);  extern void route_vty_out_flowspec(struct vty *vty, struct prefix *p,  				   struct bgp_info *binfo,  | 
