Skip to content

Instantly share code, notes, and snippets.

View arebee's full-sized avatar

Richard Burte arebee

View GitHub Profile
@arebee
arebee / disable-ssl30-windows.cmd
Last active August 29, 2015 14:07
Disable SSL 3.0 on the Server for IIS etc,
@REM Disable server side
REG ADD "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\Schannel\Protocols\SSL 3.0\Server" /VE
REG ADD "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\Schannel\Protocols\SSL 3.0\Server" /V Enabled /T REG_DWORD /D 0
@REM To force disable client side, overkill. Use client config (i.e. IE Internet Options etc.)
@REM REG ADD "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\Schannel\Protocols\SSL 3.0\Client" /VE
@REM REG ADD "HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SecurityProviders\Schannel\Protocols\SSL 3.0\Client" /V DisabledByDefault /T REG_DWORD /d 1
@arebee
arebee / ReverseString in PowerShell
Created September 30, 2014 18:26
Reverse a string in PowerShell, using an efficient StringBuilder allocation.
function reverseString
{
Param(
[string]$str
)
$sb = New-Object System.Text.StringBuilder($str.Length)
write-verbose $sb.Capacity
for ($i = ($str.Length - 1); $i -ge 0; $i--)
@arebee
arebee / IE Default reg
Created May 1, 2014 16:45
Change the default View Source editor in IE
REG ADD "HKCU\Software\Microsoft\Internet Explorer\View Source Editor\Editor Name" /t REG_SZ /d "C:\Code\Tools\Notepad2\Notepad2.exe"
@arebee
arebee / amIAdmin
Created April 29, 2014 19:52
Powershell one-liner for UAC detection.
# Will return false if you aren't in a UAC evelvated command prompt. true if you are.
(new-object System.Security.Principal.WindowsPrincipal([System.Security.Principal.WindowsIdentity]::GetCurrent())).IsInRole([System.Security.Principal.WindowsBuiltInRole]::Administrator)
@REM From http://www.windowsobserver.com/2014/04/10/add-the-missing-power-icon-on-your-surface-for-windows-8-1-update/
@REM Show power button on Start Screen
REG ADD HKCU\Software\Microsoft\Windows\CurrentVersion\ImmersiveShell\Launcher /v Launcher_ShowPowerButtonOnStartScreen /t REG_DWORD /d 1
@REM Hide power button on Start Screen
REG ADD HKCU\Software\Microsoft\Windows\CurrentVersion\ImmersiveShell\Launcher /v Launcher_ShowPowerButtonOnStartScreen /t REG_DWORD /d 0