This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* A utility function for userscripts that detects and handles AJAXed content. | |
* | |
* @example | |
* waitForKeyElements("div.comments", (element) => { | |
* element.innerHTML = "This text inserted by waitForKeyElements()."; | |
* }); | |
* | |
* waitForKeyElements(() => { | |
* const iframe = document.querySelector('iframe'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
'''Validates recently created/modified security policies | |
validate-security-policies.py | |
Author: David Cruz (davidcruz72@gmail.com) | |
Python version >= 3.9 | |
Required Python packages: | |
None | |
Features: | |
Checks for duplicate address objects |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"title": "Citrix Receiver/Workspace modifiers for Ctrl, Alt, Windows order", | |
"rules": [ | |
{ | |
"description": "In Citrix, add fn modifier to tab so it is forwarded", | |
"manipulators": [ | |
{ | |
"from": { | |
"key_code": "tab", | |
"modifiers": { "optional": [ "any" ] } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
'''Generate a list of IP addresses | |
generate-ip-addresses.py | |
Author: David Cruz (davidcruz72@gmail.com) | |
Python version >= 3.6 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python2.7 | |
import argparse | |
import json | |
import os | |
import sys | |
import urllib | |
import urllib2 | |
import xml.etree.ElementTree as ET |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
'''Parse WAN circuit details from router configurations | |
get-wan-circuit-info.py | |
Author: David Cruz (davidcruz72@gmail.com) | |
Python version >= 3.6 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
'''PAN-OS Group Object Sorter | |
pan-group-sort.py | |
Author: David Cruz (davidcruz72@gmail.com) | |
Python version >= 3.6 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
TELEGRAF_HOST=telegraf | |
INFLUXDB_HOST=influxdb | |
INFLUXDB_PORT=8086 | |
INFLUXDB_DATABASE=metrics | |
INFLUXDB_ADMIN_USER=grafana | |
INFLUXDB_ADMIN_PASSWORD=password | |
GRAFANA_PORT=3000 | |
GRAFANA_USER=admin |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<# | |
.Synopsis | |
Compile Go Apps for Multiple Platforms | |
.Parameter Platform | |
Platforms to compile for | |
.Notes | |
Developed by David Cruz | |
.Example | |
$ Build-GoSource.ps1 -Platform Windows-AMD64, Darwin-AMD64, Linux-AMD64 | |
#> |
NewerOlder