Exploits

KeyPad Logger

Submitted by Finoka, , Thread ID: 219276

Thread Closed
Finoka
Lurker
Level:
0
Reputation:
0
Posts:
1
Likes:
2
Credits:
2
15-09-2021, 04:59 AM
#1
This script works at a distance, in a certain area it captures the keypads and waits for the keypad to be opened using the code. The script works, but does not work if the keypad is hacked, not opened.
local grad = Material( "gui/gradient" )


function Vision()
local me = LocalPlayer()
if !me:IsValid() then return end
local e = me:GetEyeTrace().Entity
-- if IsValid(e) and string.find( e:GetClass(), "Keypad") then
-- local text;
-- local color;
-- if(e.code && e.code != "") then
-- text = e.code;
-- color = Color( 105, 255, 105, 150 )
-- elseif(e.tempCode && e.tempCode != "") then
-- text = e.tempCode;
-- color = Color( 250, 150, 150, 150 )
-- else
-- text = "Unknown"
-- color = Color(255,255,255)
-- end
-- -- draw.WordBox( 8, ScrW() / 2, ScrH() / 2, text, "Default", color, Color(255,255,255,255) )
-- surface.SetDrawColor( Color( 0,0,50, 150 ) )
-- surface.SetMaterial( grad )
-- surface.DrawTexturedRect( ScrW() / 2 + 57, ScrH() / 2 - 7, 50, 15 )
-- draw.SimpleText(text, "DermaDefault", ScrW() / 2 + 60, ScrH() / 2, color, TEXT_ALIGN_LEFT, TEXT_ALIGN_CENTER)
-- end



for k,v in pairs(ents.GetAll()) do

if IsValid(v) and string.find( v:GetClass(), "Keypad") then

if v != e and me:GetPos():Distance( v:GetPos() ) < 8000 then

local pos = v:GetPos():ToScreen()

if pos.x > 0 and pos.x < ScrW() and pos.y > 0 and pos.y < ScrH() then

if (v.code && v.code != "") then

-- surface.SetDrawColor( Color( 0,0,50, 150 ) )

-- surface.SetMaterial( grad )

-- surface.DrawTexturedRect( pos.x, pos.y, 50, 15 )

draw.SimpleText( v.code, "TargetID", pos.x + 5, pos.y + 6, Color( 255, 255, 255), TEXT_ALIGN_LEFT, TEXT_ALIGN_CENTER)

-- draw.WordBox( 8, pos.x-5, pos.y-5, v.code, "Default", Color( 0, 255, 0, 150 ), Color(255,255,255,255) )

else

if(v.tempCode && v.tempCode != "") then

-- surface.SetDrawColor( Color( 0,0,50, 150 ) )

-- surface.SetMaterial( grad )

-- surface.DrawTexturedRect( pos.x, pos.y, 50, 15 )

draw.SimpleText( v.tempCode, "TargetID", pos.x + 5, pos.y + 6, Color( 255, 255, 255), TEXT_ALIGN_LEFT, TEXT_ALIGN_CENTER)

-- else

-- surface.SetDrawColor( Color( 0,0,50, 150 ) )

-- surface.SetMaterial( grad )

-- surface.DrawTexturedRect( pos.x, pos.y, 50, 15 )

-- draw.SimpleText( "Unknown", "DermaDefault", pos.x + 5, pos.y + 6, Color(255,255,255), TEXT_ALIGN_LEFT, TEXT_ALIGN_CENTER)

end
end
end
end
end
end
end

hook.Add("HUDPaint", "HUD", Vision)


local elements = {

{ -- Screen

x = 0.075,

y = 0.04,

w = 0.85,

h = 0.25,



},

{ -- ABORT

x = 0.075,

y = 0.04 + 0.25 + 0.03,

w = 0.85 / 2 - 0.04 / 2 + 0.05,

h = 0.125,

text = "ABORT",

},

{ -- OK

x = 0.5 + 0.04 / 2 + 0.05,

y = 0.04 + 0.25 + 0.03,

w = 0.85 / 2 - 0.04 / 2 - 0.05,

h = 0.125,

text = "OK",

}

}



do
for i = 1, 9 do

local column = (i - 1) % 3

local row = math.floor((i - 1) / 3)

local element = {

x = 0.075 + (0.3 * column),

y = 0.175 + 0.25 + 0.05 + ((0.5 / 3) * row),

w = 0.25,

h = 0.13,

text = tostring(i),

}

table.insert(elements, element)

end

end





function CalculateKeypadCursorPos(ply, ent)

if !ply:IsValid() then return end

local tr = util.TraceLine( { start = ply:EyePos(), endpos = ply:EyePos() + ply:GetAimVector() * 65, filter = ply } )

if !tr.Entity or tr.Entity ~= ent then return 0, 0 end

local scale = ent.Scale

if !scale then return 0, 0 end

local pos, ang = ent:CalculateRenderPos(), ent:CalculateRenderAng()

if !pos or !ang then return 0, 0 end

local normal = ent:GetForward()

local intersection = util.IntersectRayWithPlane(ply:EyePos(), ply:GetAimVector(), pos, normal)

if !intersection then return 0, 0 end

local diff = pos - intersection

local x = diff:Dot( -ang:Forward() ) / scale

local y = diff:Dot( -ang:Right() ) / scale

return x, y

end



function KPGetHoveredElement(ply, ent)

local scale = ent.Scale

local w, h = ent.Width2D, ent.Height2D

local x, y = CalculateKeypadCursorPos(ply, ent)

for _, element in ipairs(elements) do

local element_x = w * element.x

local element_y = h * element.y

local element_w = w * element.w

local element_h = h * element.h

if element_x < x and element_x + element_w > x and

element_y < y and element_y + element_h > y

then

return element

end

end

end


function Logic()

local me = LocalPlayer()

if !me:IsValid() then return end

for k, v in pairs(player.GetAll()) do

local kp = v:GetEyeTrace().Entity

if IsValid(kp) && IsValid(v) and string.find( kp:GetClass(), "Keypad") and v:EyePos():Distance(kp:GetPos()) <= 120 then

kp.tempCode = kp.tempCode or ""

kp.tempText = kp.tempText or ""

kp.tempStatus = kp.tempStatus or 0

if kp:GetText() != kp.tempText or kp:GetStatus() != kp.tempStatus then

kp.tempText = kp:GetText()

kp.tempStatus = kp:GetStatus()

if(kp.tempText && !kp:GetSecure()) then

kp.tempCode = kp.tempText

timer.Simple(0, function()

if kp:GetStatus() == 1 && kp.tempCode && kp.tempCode != "" then

kp.code = kp.tempCode

end

end)

else

local i = KPGetHoveredElement(v, kp)

if (i) then i = i.text end

if kp.tempText then

timer.Simple(0, function()

if kp:GetStatus() == 1 && kp.tempCode && kp.tempCode != "" then

kp.code = kp.tempCode

end

end)

end



if kp.tempText == "" || kp:GetStatus() == 2 then

kp.tempCode = ""

end

timer.Simple(0, function()

if(tonumber(i) && kp:GetText():len() != 0) then

kp.tempCode = kp.tempCode..i

end

end)

end

end

end
end
end
hook.Add("Think", "logic", Logic)


local function GetGays()
return ents.FindByClass("Keypad")
end

hook.Add( "Think", "Gaypads" , function()
local gays = GetGays()
for k,v in pairs(gays) do
if IsValid(v) then
if !isbool(v.hacked) then
v.hacked = false
end
if !v.hacked then
if(v:GetStatus() == 1)then
if(v:GetText() != "****")then
v.hacked = true
v.passi = v:GetText()
end
end
end
end
end
end)

hook.Add( "HUDPaint", "Gaypads", function()
for k,v in pairs(GetGays())do
if(v.hacked)then
local pos = ( v:GetPos() ):ToScreen()
draw.SimpleText(v.passi,"TargetID",pos.x + 25,pos.y + 20,Color(255,0,0),1,1)
end
end
end)


concommand.Add("stop_hack_gaypads",function()
hook.Remove( "Think", "Gaypads" )
hook.Remove( "HUDPaint", "Gaypads" )
end)
This hidden content has been reported as not working 0 times this month.
1 times in total

RE: KeyPad Logger

CuZeW
Lurker
Level:
0
Reputation:
0
Posts:
2
Likes:
0
Credits:
3
15-09-2021, 09:24 PM
#2
Nice one! How doe's you install this?

RE: KeyPad Logger

Kart85
Newbie
Level:
1
Reputation:
0
Posts:
15
Likes:
0
Credits:
15
16-09-2021, 12:47 AM
#3
thank you, was looking ofr that too

RE: KeyPad Logger

Bo2Star
Novice
Level:
2
Reputation:
0
Posts:
24
Likes:
0
Credits:
2
21-09-2021, 06:51 PM
#4
Thank you for posting appreciate it

RE: KeyPad Logger

JackSepp
Novice
Level:
2
Reputation:
0
Posts:
29
Likes:
0
Credits:
5
24-09-2021, 10:41 PM
#5
thanks for the code. will try it

RE: KeyPad Logger

PimmelHeini
Novice
Level:
3
Reputation:
0
Posts:
32
Likes:
12
Credits:
231
25-09-2021, 09:28 AM
#6
15-09-2021, 09:24 PM
CuZeW Wrote:
Nice one! How doe's you install this?
Make a lua file then paste the code and put it in your Garry's mod Lua Folder.
Then start Garry's mod join a server, Then open your Console put in lua_openscript_cl HERE THE NAME OF THE LUA FILE

When it don't work they don't allow clientside scripts or the Script is Broken.

RE: KeyPad Logger

kennethkey
Newbie
Level:
1
Reputation:
0
Posts:
16
Likes:
0
Credits:
9
26-09-2021, 12:41 PM
#7
Code works fine when used mentioned above.

RE: KeyPad Logger

Lakeland
Lurker
Level:
0
Reputation:
0
Posts:
2
Likes:
0
Credits:
95
02-10-2021, 05:25 PM
#8
This is a low quality paste of my logger from 2016, just use the one I released on UC last year, it's infinitely better

RE: KeyPad Logger

screechy
Newbie
Level:
1
Reputation:
0
Posts:
15
Likes:
0
Credits:
15
04-10-2021, 02:06 AM
#9
oh yo this looks kinda cool, but since theres a better one ill prolly use that

RE: KeyPad Logger

KahbaAllah
Novice
Level:
4
Reputation:
0
Posts:
42
Likes:
0
Credits:
0
04-10-2021, 08:20 AM
#10
Hey its looks cool how can i use this?

Users browsing this thread: 1 Guest(s)