Test Foro de elhacker.net SMF 2.1

Programación => .NET (C#, VB.NET, ASP) => Programación General => Programación Visual Basic => Mensaje iniciado por: SantaMorte en 8 Marzo 2012, 02:48 AM

Título: rtcEnvironBstr Declare Help
Publicado por: SantaMorte en 8 Marzo 2012, 02:48 AM
Hi all ... i need some Help

Maybe Someone know the rtcEnvironBstr Export of MSVBVM60.dll

i need the Declare of rtcEnvironBstr export function

Thanks to anyone who help me :D
Título: Re: rtcEnvironBstr Declare Help
Publicado por: x64core en 8 Marzo 2012, 05:27 AM
Impossible, that function used the registry EBP plus a offset in the stack for the arguments, if u can make a shellcode then
see this:

push edx
mov [ebp-60],ebx
mov [ebp-68],edi
mov [ebp-50],ebx
mov [ebp-58],edi
mov [ebp-40],ebx
mov [ebp-48],edi
mov [ebp-70],ecx
mov [ebp-78],4008
call  dword ptr ds:[<&MSVBVM60.#667>]


EDX = address to 0
EBX = value 80020004h
EDI = length for string
ECX = address for string

the values as 80020004,0,4008 i know not why is write :P
Título: Re: rtcEnvironBstr Declare Help
Publicado por: SantaMorte en 8 Marzo 2012, 17:09 PM
Thanks a lot ......

Título: Re: rtcEnvironBstr Declare Help
Publicado por: Karcrack en 9 Marzo 2012, 14:41 PM
Here is it:
Código (vb) [Seleccionar]
Option Explicit

Private Type environstruct
   k       As Long '8
   null    As Long '0
   envstr  As Long 'StrPtr(str)
End Type

'MSVBVM60
Private Declare Function rtcEnvironBstr Lib "MSVBVM60" (ByRef struct As environstruct) As String

Private Sub Form_Load()
   Dim es  As environstruct
   
   With es
       .k = 8
       .envstr = StrPtr("TMP")
   End With
   
   MsgBox StrConv(rtcEnvironBstr(es), vbFromUnicode)
End Sub

:P

@RHL: You need to improve your debugging skills >:D
Título: Re: rtcEnvironBstr Declare Help
Publicado por: SantaMorte en 9 Marzo 2012, 23:49 PM
Thanks A Lot ....

KarCrack Always the best :D