From 0e25309411b5583c08c066a9a430069a7785d900 Mon Sep 17 00:00:00 2001 From: Alexandre Dulaunoy Date: Sun, 17 Sep 2017 13:55:49 +0200 Subject: [PATCH] values_list added in the documentation --- tools/adoc_objects.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/tools/adoc_objects.py b/tools/adoc_objects.py index 83933c4..bd6e0f5 100755 --- a/tools/adoc_objects.py +++ b/tools/adoc_objects.py @@ -77,7 +77,7 @@ def asciidoc(content=False, adoc=None, t='title',title=''): #output = '\n{}\n'.format #output = '[cols=\",a\"]\n' output = output + '|===\n' - output = output + '|Object attribute | MISP attribute type | Description | Disable correlation\n' + output = output + '|Object attribute | MISP attribute type | Description | Disable correlation\n' adoc = adoc + output for v in content['attributes']: disableCorrelation = 'icon:minus[] ' @@ -87,7 +87,10 @@ def asciidoc(content=False, adoc=None, t='title',title=''): disableCorrelation = 'icon:check[] ' if 'description' in content['attributes'][v]: if content['attributes'][v]['description']: - description = content['attributes'][v]['description'] + values = '' + if 'values_list' in content['attributes'][v]: + values = content['attributes'][v]['values_list'] + description = '{} {}'.format(content['attributes'][v]['description'],values) output = '\n| {} | {} a| {} a| {}\n'.format(v, content['attributes'][v]['misp-attribute'], description ,disableCorrelation) adoc = adoc + output output = '\n|===\n'