Skip to content

Instantly share code, notes, and snippets.

/* WARNING: Function: _guard_xfg_dispatch_icall_nop replaced with injection: guard_dispatch_icall */
/* WARNING: Globals starting with '_' overlap smaller symbols at the same address */
/* public: static bool __cdecl CMsiSecureRepairManager::NeedsSecureRepair(unsigned short const *
__ptr64,enum eSecRepairModeEnum & __ptr64) */
bool __cdecl CMsiSecureRepairManager::NeedsSecureRepair(ushort *param_1,eSecRepairModeEnum *param_2)
{
bool bVar1;
# Automation of this guide:
# https://www.reddit.com/r/cs2/comments/1apx40j/comment/kq9ay6u
# from u/El_Chapaux
Function Get-FileSize {
Param(
$length
)
If ($length -ge 1TB) {
return '{0:N2} TB' -f ($length / 1TB)
$WShell = New-Object -com "Wscript.Shell"
while ($true) {
$WShell.sendkeys("{SCROLLLOCK}")
Start-Sleep -Milliseconds 100
$WShell.sendkeys("{SCROLLLOCK}")
# Start-Sleep -Seconds 600 # 10 min
Start-Sleep -Seconds 240 # 4 min
}
timeout 60
Set-StrictMode -Version 3.0
# rewrite of: https://github.com/iidanL/InstallWindowsWithoutUSB
If (!([Security.Principal.WindowsPrincipal][Security.Principal.WindowsIdentity]::GetCurrent()).IsInRole([Security.Principal.WindowsBuiltInRole]'Administrator')) {
# Ist kein Admin, wird neu als Admin gestartet
$filename = (Get-ChildItem $PSCommandPath).Name
$CWD = [Environment]::CurrentDirectory
Start-Process powershell.exe -ArgumentList "-NoProfile -NoExit -Command &{cd '$CWD';.\\$filename}" -Verb RunAs
Exit
Get-ChildItem -Path $env:windir\winsxs | Select-Object "Name"
Get-ChildItem -Path $env:windir\winsxs | ForEach-Object {
if ($_.Name -like "*msxml*") {
Get-ChildItem -Path $_.FullName -Recurse | ForEach-Object {
$item = Get-Item $_.FullName
if ($item -is [System.IO.FileInfo]) { # Datei
if ($item.LinkType -eq "HardLink") {
Write-Host "$($_.Target.Count) $($_.FullName)"
if ($_.Target.Count -ne 1) {
HRESULT FUN_180057c30(IID *param_1,LPUNKNOWN param_2,DWORD param_3,IID *param_4,longlong **param_5)
{
longlong *plVar1;
undefined4 *puVar2;
undefined4 uVar3;
undefined4 uVar4;
undefined4 uVar5;
DWORD DVar6;
DWORD DVar7;
# $VerbosePreference = "continue"
$TestValues = [System.Collections.ArrayList](
[PSCustomObject]@{
Description = "Short, Fixed, High foreground boost."
HexValue = "2A"
DecValue = "42"
},
[PSCustomObject]@{
Description = "Short, Fixed, Medium foreground boost."
# https://web.archive.org/web/20190115225109/https://blogs.technet.microsoft.com/askperf/2008/01/11/getting-started-with-svchost-exe-troubleshooting/
$IsolatedServices = @("AudioSrv", "AudioEndpointBuilder")
$SvchostPath = 'HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Svchost'
$ServicesPath = 'HKLM:\SYSTEM\CurrentControlSet\Services'
function Register-NewGroup {
param(
[string]$Path,
[string]$Group
powershell -NoProfile -NoLogo -c "& {$h=$(Get-FileHash '%*' -Algorithm SHA256).Hash; $f=gci '%*'; Rename-Item -Path '%*' -NewName """$($f.Directory)\$($f.BaseName)_$h$($f.Extension)""" }"
# https://learn.microsoft.com/en-us/archive/blogs/jhoward/announcing-nvspbind
$SettingsFile = "$((Get-Location).Path)\settings.xml"
$NetworkAdapter = 'Ethernet'
$title = 'Network Settings'
###
# Get-NetAdapterBinding -IncludeHidden -Name Ethernet -AllBindings
$tweakSettings = @("ms_rdma_ndk", "ms_tcpip", "ms_pppoe", "ms_netbt")