Skip to content

Instantly share code, notes, and snippets.

View 0XDE57's full-sized avatar

arbitrary hexcode 0XDE57

View GitHub Profile
@0XDE57
0XDE57 / RestartWifiAdapter.ps1
Last active December 20, 2016 06:15
Restart wifi adapter on laptop after waking from sleep. Solution to some strange driver bug on win7 x86 Intel n7620 wifi card. Auto run on wake up with Task Scheduler: On Event > System > Kernel-Power > 42
# Get the network adapter object
$adapter = Get-WmiObject -Class Win32_NetworkAdapter | Where-Object {$_.Name -eq "Intel(R) Wireless-N 7260"}
# Disable it
Write-Host -nonew "Disabling Network Adapter $($adapter.Name) ... ";
$result = $adapter.Disable()
if ($result.ReturnValue -eq -0) {
Write-Host "Success.";
} else {
Write-Host "Failed.";
Windows Registry Editor Version 5.00
;Force ask password on UAC for admin and users
;https://msdn.microsoft.com/en-us/library/cc232761.aspx
[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System]
"ConsentPromptBehaviorAdmin"=dword:00000003
"ConsentPromptBehaviorUser"=dword:00000003
@0XDE57
0XDE57 / DisableUpdateAutoReboot.reg
Created July 6, 2016 01:55
Disable the auto reboot update dialog in Win7/8. No more postpone for 4 hours.
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU]
"NoAutoRebootWithLoggedOnUsers"=dword:00000001