Skip to content

Instantly share code, notes, and snippets.

Avatar

Whilow 0XDE57

View GitHub Profile
@0XDE57
0XDE57 / disableGPU.sh
Created Nov 24, 2019
Recovery util to re-disable gpu in my dead 2011 macbook when it decides to not boot or you have to reset PRAM (Command, Option, P, and R)
View disableGPU.sh
cd /
umount /sys/firmware/efi/efivars/
mount -t efivarfs rw /sys/firmware/efi/efivars/
cd /sys/firmware/efi/efivars/
printf "\x07\x00\x00\x00\x01\x00\x00\x00" > /sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9
chattr +i "/sys/firmware/efi/efivars/gpu-power-prefs-fa4ce28d-b62f-4c99-9cc3-6815686e30f9"
cd /
umount /sys/firmware/efi/efivars/
@0XDE57
0XDE57 / DisableAeroShake.reg
Created Dec 20, 2016
Disable win7 effect to minimize all windows when shaking selected window.
View DisableAeroShake.reg
Windows Registry Editor Version 5.00
[HKEY_CURRENT_USER\Software\Policies\Microsoft\Windows\Explorer]
"NoWindowMinimizingShortcuts"=dword:00000001
@0XDE57
0XDE57 / RestartWifiAdapter.ps1
Last active Dec 20, 2016
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
View RestartWifiAdapter.ps1
# 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.";
View UACPromptAdminPassword.reg
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 / TakeOwnership.reg
Created Jul 8, 2016
Mirror/backup of Take Ownership context menu shortcut command. I did not write this, can't find origin to give credit.
View TakeOwnership.reg
Windows Registry Editor Version 5.00
[HKEY_CLASSES_ROOT\*\shell\runas]
@="Take Ownership"
"NoWorkingDirectory"=""
[HKEY_CLASSES_ROOT\*\shell\runas\command]
@="cmd.exe /c takeown /f \"%1\" && icacls \"%1\" /grant administrators:F"
"IsolatedCommand"="cmd.exe /c takeown /f \"%1\" && icacls \"%1\" /grant administrators:F"
@0XDE57
0XDE57 / DisableUpdateAutoReboot.reg
Created Jul 6, 2016
Disable the auto reboot update dialog in Win7/8. No more postpone for 4 hours.
View DisableUpdateAutoReboot.reg
Windows Registry Editor Version 5.00
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\Windows\WindowsUpdate\AU]
"NoAutoRebootWithLoggedOnUsers"=dword:00000001
@0XDE57
0XDE57 / start pnkbstr(run as admin).bat
Last active Jul 8, 2016
Script for enabling and disabling punkbuster malware when I want to play battlefield. Must be run as admin.
View start pnkbstr(run as admin).bat
@ECHO OFF
::Flush DNS cache before starting anti-cheat software.
::I don't think punkbuster checks the DNS but VAC does: https://www.reddit.com/r/GlobalOffensive/comments/1y0kc1/
::This is just a precaution. pnkbstr is still a joke ;)
ECHO Flushing DNS...
ipconfig /flushdns
::Start A so we can play the game without being kicked.
ECHO Starting Punkbuster...
NET START "PnkBstrA"
@0XDE57
0XDE57 / config.md
Last active Sep 25, 2020
Firefox about:config privacy settings
View config.md

ABOUT

about:config settings to harden the Firefox browser. Privacy and performance enhancements.
To change these settings type 'about:config' in the url bar. Then search the setting you would like to change and modify the value. Some settings may break certain websites from functioning and rendering normally. Some settings may also make firefox unstable.

I am not liable for any damages/loss of data.

Not all these changes are necessary and will be dependent upon your usage and hardware. Do some research on settings if you don't understand what they do. These settings are best combined with your standard privacy extensions (HTTPS Everywhere, NoScript/Request Policy, uBlock origin, agent spoofing, Privacy Badger etc), and all plugins set to "Ask To Activate".

You can’t perform that action at this time.