Skip to content

Instantly share code, notes, and snippets.

View jamesperrin's full-sized avatar
✝️
Working it

James Perrin jamesperrin

✝️
Working it
View GitHub Profile
##################################################################################
#
# Purpose: To registry proxy SSL certificate with Fortify Java.
# OS: Windows
# Terminal: PowerShell
#
# James Perrin, @jamesperrin | https://github.com/jamesperrin
# Licensed under CC0-1.0 (https://creativecommons.org/publicdomain/zero/1.0/)
##################################################################################
::*********************************************************************************
::
:: Title: RunAs Smartcard User Script
::
:: Purpose: This script runs a selected program as a Smartcard User
::
:: Note: The Windows service "Secondary Logon" needs to running for script to work.
::
:: To run service:
::
import os
import shutil
import errno
# def copyanything(src, dst):
# try:
# shutil.copytree(src, dst)
# except OSError as exc: # python >2.5
# if exc.errno == errno.ENOTDIR:
# shutil.copy(src, dst)
<#
::##################################################################################
::#
::# Purpose: To configure HTTP Strict Transport Security (HSTS) Window Server versions 2019 with IIS 10.
::# OS: Window Server versions 2019 with IIS 10
::# SEE: https://docs.microsoft.com/en-us/iis/get-started/whats-new-in-iis-10-version-1709/iis-10-version-1709-hsts#iis-100-version-1709-native-hsts-support
::#
::# James Perrin, MIT License, https://www.countrydawgg.com, | @_jamesperrin
::#
::##################################################################################
# Created by Next.js - https://gist.github.com/jamesperrin/d7d030d7e8064920fa55a75b408885e4
# dependencies
/node_modules
/.pnp
.pnp.js
# testing
/coverage
# next.js
#!/bin/bash
set -m
##################################################################################
#
# Purpose: To registry proxy SSL certificate with Fortify Java.
# OS: Windows
# Terminal: Git Bash for Windows
#
# James Perrin, @jamesperrin | https://github.com/jamesperrin
@jamesperrin
jamesperrin / WindowsServerHTTPSecurity.ps1
Last active July 30, 2024 16:50
PowerShell script to configure Windows Server HTTP protocols
##################################################################################
#
# Purpose: This script automates the process of configuring HTTP Protocols settings on Windows Server 2012 R2 and higher.
#
# Note: This script requires elevated privileges since it's modifying Windows Server registry settings.
#
# File: WindowsServerHTTPSecurity.ps1
# Date: 12/05/2019
#
# OS: Windows
@jamesperrin
jamesperrin / github-labels-import.js
Last active June 29, 2024 17:06
JavaScript file for importing GitHub labels from a JSON object.
/*
Purpose: Import settings for GitHub Labels.
(c) James Perrin, MIT License, https://www.countrydawgg.com, | @jamesperrin
Importing Instructions:
1. Update the labels JSON object.
2. Open a web browser.
3. Navigate to the desired GitHub repository.
@jamesperrin
jamesperrin / github-labels-export.js
Last active October 2, 2024 14:36
JavaScript file for exporting GitHub labels to a JSON object.
/*
Purpose: Export the configuration settings for GitHub Labels.
(c) James Perrin, MIT License, https://www.countrydawgg.com, | @jamesperrin
Exporting Instructions:
1. Open a web browser.
2. Navigate to the desired GitHub repository.
3. Navigate to Issues tab.
/*
* jQuery plugin that converts value to date
* @requires https://jqueryui.com/
* @param {Node} True or False to Disable element
* @return {String} Formatted date
*/
(function ($) {
$.fn.getDateMmddyy = function () {
if (this.val() == null) {
return null;