Skip to content

Instantly share code, notes, and snippets.

View metablaster's full-sized avatar
😎
Chilling out

metablaster

😎
Chilling out
  • European Union
View GitHub Profile
@plembo
plembo / you-need-spice-vdagent.md
Last active October 22, 2024 20:17
You need spice-vdagent

You need spice-vdagent

Debian or Kali Linux installed to as KVM (libvirtd) guests do not automatically have qemu-guest-agent or spice-vdagent installed. This will prevent seamless movement of the mouse cursor between the guest and host desktop in Virtual Machine Manager (requiring the use of a Ctrl-Alt to release the cursor from the guest window).

To cure this, install both qemu-guest-agent and spice-vdagent on each guest and reboot (the guests).

$ sudo apt install qemu-guest-agent
$ sudo apt install spice-vdagent
@AveYo
AveYo / .. MediaCreationTool.bat ..md
Last active November 10, 2024 14:53
Universal MediaCreationTool wrapper for all MCT Windows 10 versions - MOVED TO github.com/AveYo/MediaCreationTool.bat
@h3nryza
h3nryza / powerShellLocalGroup.ps1
Created July 17, 2018 17:45
Powershell get users of a local computer group
Get-CimInstance Win32_GroupUser | where {$_.GroupComponent -like "*admini*"} |select -ExpandProperty PartComponent
@Odepax
Odepax / 1-PowerShell-Tips.md
Last active December 1, 2023 09:33
What I Understand about PowerShell Approved Verbs

PowerShell Tips

Write-Host vs Write-Output

Write-Host writes directly to the console; Write-Output writes to the pipeline, which often ends up to the console but not necessarily.

For example: Write-Host "The Cake is a lie" | Out-Null won't work as expected, Write-Output "The Cake is a lie" | Out-Null will.

False Friends

@ikrima
ikrima / buildconfiguration.xml
Last active September 1, 2019 14:37
Useful UBT flags/variables
<?xml version="1.0" encoding="utf-8" ?>
<Configuration xmlns="https://www.unrealengine.com/BuildConfiguration">
<BebylonBuildConfiguration>
<bBBLivePPEnabled>true</bBBLivePPEnabled> <!-- /* d=false */ -->
<bBBIGMemTraceEnabled>false</bBBIGMemTraceEnabled> <!-- /* d=false */ -->
<bBBMicroProfileEnabled>true</bBBMicroProfileEnabled> <!-- /* d=true */ -->
<bBBPythonEnabled>true</bBBPythonEnabled> <!-- /* d=true */ -->
<BBCompileAssertLevel>4</BBCompileAssertLevel>
<bBBExperimentalFeaturesEnabled>true</bBBExperimentalFeaturesEnabled> <!-- /* d=false */ -->
</BebylonBuildConfiguration>
@dknoodle
dknoodle / Windows Defender Exclusions VS 2017.ps1
Last active October 31, 2024 14:54
Adds Windows Defender exclusions for Visual Studio 2017
$userPath = $env:USERPROFILE
$pathExclusions = New-Object System.Collections.ArrayList
$processExclusions = New-Object System.Collections.ArrayList
$pathExclusions.Add('C:\Windows\Microsoft.NET') > $null
$pathExclusions.Add('C:\Windows\assembly') > $null
$pathExclusions.Add($userPath + '\AppData\Local\Microsoft\VisualStudio') > $null
$pathExclusions.Add('C:\ProgramData\Microsoft\VisualStudio\Packages') > $null
$pathExclusions.Add('C:\Program Files (x86)\MSBuild') > $null
$pathExclusions.Add('C:\Program Files (x86)\Microsoft Visual Studio 14.0') > $null
@mklement0
mklement0 / Test-WinCredential.ps1
Last active April 18, 2024 01:33
Test-WinCredential: PowerShell function for validating Windows domain / local user credentials.
<#
Prerequisites: Windows PowerShell 5.1, PowerShell (Core) (v6+) - MAY work in earlier versions
License: MIT
Author: Michael Klement <mklement0@gmail.com>
DOWNLOAD and INSTANT DEFINITION OF THE FUNCTION:
irm https://gist.github.com/mklement0/83e8e6a2b39ecec7b0a14a8e631769ce/raw/Test-WinCredential.ps1 | iex
@yellowbyte
yellowbyte / compiling_asm.md
Last active October 14, 2024 15:56
how to assemble assembly with NASM assembler to 32-bit or 64-bit ELF binary with or without libc

32-bit ELF binary

how to assemble and link:

nasm -f elf32 -o <filename>.o <filename>.asm
ld -m elf_i386 -o <filename> <filename>.o

template code (hello world):

section .text
global _start
@ozyx
ozyx / tasks.json
Last active August 27, 2021 10:12
Assemble, Link and Execute MASM as default build task in VSCode (with problem matcher)
{
// See https://go.microsoft.com/fwlink/?LinkId=733558
// for the documentation about the tasks.json format
"version": "2.0.0",
"tasks": [
{
"label": "assemble",
"type": "shell",
"args": [
"/c",
@nohwnd
nohwnd / Uninstall-Pester.ps1
Last active July 5, 2024 03:59
Remove built-in version of Pester 3 (or -All) from Windows 10 Program Files and Program Files (x86).
#Requires -RunAsAdministrator
function Uninstall-Pester ([switch]$All) {
if ([IntPtr]::Size * 8 -ne 64) { throw "Run this script from 64bit PowerShell." }
#Requires -RunAsAdministrator
$pesterPaths = foreach ($programFiles in ($env:ProgramFiles, ${env:ProgramFiles(x86)})) {
$path = "$programFiles\WindowsPowerShell\Modules\Pester"
if ($null -ne $programFiles -and (Test-Path $path)) {
if ($All) {