Added fix for CWE 330: Use of Insufficiently Random Value (Cryptographically weak PRNG)
Change-Id: Iddd9dc85a5be84371c8d6afb47d4571f67af3468
Signed-off-by: Adurti <adurti.v@tataelxsi.co.in>
# import json
# import tarfile
from time import sleep
-from random import randint
+import random
import os
from sys import stderr
from uuid import uuid4
headers = headers_yaml
else:
headers = headers_zip_yaml
- if randint(0, 1) == 0:
+ if random.SystemRandom().randint(0, 1) == 0:
# vnfd CREATE AND UPLOAD in one step:
engine.test(
"Onboard VNFD in one step",
else:
headers = headers_zip_yaml
- if randint(0, 1) == 0:
+ if random.SystemRandom().randint(0, 1) == 0:
# nsd CREATE AND UPLOAD in one step:
engine.test(
"Onboard NSD in one step",