Skip to content

Instantly share code, notes, and snippets.

@tjarrettveracode
tjarrettveracode / pre-request.js
Last active May 3, 2022 17:49
This gist is deprecated. Please use the pre-request script found at https://github.com/veracode/veracode-postman.
var url = require('url');
const id = 'YOUR_VERACODE_API_KEY_ID';
const key = 'YOUR_VERACODE_API_KEY_SECRET';
const authorizationScheme = 'VERACODE-HMAC-SHA-256';
const requestVersion = "vcode_request_version_1";
const nonceSize = 16;
function computeHashHex(message, key_hex) {
@tjarrettveracode
tjarrettveracode / createcredentials.py
Created October 23, 2020 14:43
Simple Python script to create a Veracode credentials file. Useful in environments like Pythonista.
import os
def create_folder(directory):
try:
if not os.path.exists(directory):
os.makedirs(directory)
except OSError:
print('Error: Creating directory. ' + directory)
#edit this to reflect your local Pythonista directory. You can try the following in a python console
{
"MRData": {
"xmlns": "http:\/\/ergast.com\/mrd\/1.4",
"series": "f1",
"url": "http://ergast.com/api/f1/2018/circuits.json",
"limit": "30",
"offset": "0",
"total": "21",
"CircuitTable": {
"season": "2018",