Skip to content

Instantly share code, notes, and snippets.

@JaimeStill
JaimeStill / README.md
Last active December 12, 2021 10:42
Active Directory Authorization Workflow
@JaimeStill
JaimeStill / README.md
Last active April 12, 2024 06:47
ASP.NET Core Active Directory Integration

Active Directory Authentication

This will provide an example of integrating Active Directory authentication in an ASP.NET Core app.

Note, you'll need to be running on a Windows domain with Visual Studio debugging in IIS Express for this to work.

Setup

In launchSettings.json, you'll want to modify iisSettings by turning on windowsAuthentication:

@manne
manne / azure-devops-themes-custom-properties.css
Created November 28, 2018 12:47
Defined custom properties of Azure DevOps Dark Theme
:root {
--palette-primary-shade-30: 184, 216, 255;
--palette-primary-shade-20: 152, 198, 255;
--palette-primary-shade-10: 121, 181, 255;
--palette-primary: 0, 120, 212;
--palette-primary-tint-10: 82, 143, 217;
--palette-primary-tint-20: 73, 126, 191;
--palette-primary-tint-30: 55, 96, 145;
--palette-primary-tint-40: 34, 59, 89;
--palette-neutral-100: 255, 255, 255;
@ramondeklein
ramondeklein / CreateCaCert.ps1
Last active August 25, 2022 17:18
Script to generate ca-cert.crt file based on the Windows Certificate store
# This script can be used to generate a ca-cert.crt file that can be used by
# Unix-based utilities like curl, git, ...
#
# It allows you to synchronize the root certificates (CA) based on the
# certificates installed in your Windows certification stores. You can also
# get a list from Mozilla, but I think it's convenient to have the same CA
# certificates in all tools.
#
# Some examples on how to use this script:
#
@shacker
shacker / gist:87908e13c9ee6655ce90
Last active October 5, 2023 17:46
Using the Workday API with Python and the suds client library
import sys
from suds import client
from suds.wsse import Security, UsernameToken
from suds.sax.text import Raw
from suds.sudsobject import asdict
from suds import WebFault
'''
Given a Workday Employee_ID, returns the last name of that employee.
@shovon
shovon / increase_swap.sh
Created April 10, 2015 15:18
Increasing swap size. Only tested on the ubuntu/trusty64 Vagrant box. CREDIT GOES TO ---> http://jeqo.github.io/blog/devops/vagrant-quickstart/
#!/bin/sh
# size of swapfile in megabytes
swapsize=8000
# does the swap file already exist?
grep -q "swapfile" /etc/fstab
# if not then create it
if [ $? -ne 0 ]; then
@BenNeise
BenNeise / ConvertTo-Markdown.ps1
Last active January 12, 2021 18:26
ConvertTo-Markdown
<#
.Synopsis
Converts a PowerShell object to a Markdown table.
.EXAMPLE
$data | ConvertTo-Markdown
.EXAMPLE
ConvertTo-Markdown($data)
#>
Function ConvertTo-Markdown {
[CmdletBinding()]
@sayedihashimi
sayedihashimi / add-function-with-param.ps1
Created February 3, 2014 05:57
PowerShell: Add a function with a parameter to an object
$result | Add-Member -MemberType ScriptMethod ExpandString -Value {
[cmdletbinding()]
param(
[Parameter(
Mandatory=$true)]
[string]
$unexpandedValue
)
process{
if($this.ProjectInstance){