Home Upgrade Search Memberlist Extras Hacker Tools Award Goals Help Wiki Contact

.NET 

[Tut] bypass any login form [[ with Assembly & Activator ]]

want to learn how to bypass login forms ?
and such things ? you came to the best place.
it work on protected .net files too.

EXPLAIN ::
with this methood we can pass on all .net file 'Forms'
so if we have an application with login form.
we can use this methood to bypass the 'login' form.

Code
code was update'd
[now accept parameters too]
http://pastebin.com/26wJGqRz

// lets create a form list.
Code
var formList = new List<Form>();

// let create assembly
Code
var asm = Assembly.LoadFile(@"youFileHere");

// get all types
Code
var types = asm.GetTypes();

// move on all the types and check what is form
// add it to the list
Code
for (int i = 0; i < typeList.Length; i++)
{
    if (typeList[i].IsClass &&
  typeList[i].IsSubclassOf(typeof(Form)))
    {
  formList.Add(
    Activator.CreateInstance(typeList[i]) as Form);
    }
}

// now all you have to do is this.
Code
for (int i = 0; i < formList.Count; i++)
{
    formList[i].ShowDialog();
}

&&& FUll code &&&
[img]http://lulzimg.com/i23/55b109.png[/img]
I have no idea what this is supposed to do. Please explain more.
ye... i agree with the post above.

[Image: LAkH6rH.png]

My Steam Profile (from SteamDB)

Worth: $933.48 ($344.19 with sales)
Hours spent: 3,580.9h[/list]


I kind of get it (i think), well at least the first part... It's getting the amount of forms in a file?
(Jun 23, 2011 02:13 PM).bLaZeD Wrote:  I have no idea what this is supposed to do. Please explain more.

I think he's using reflection to load the main form of an application. That way, you don't need to login....

EDIT: It gets all the forms and shows all of them =)
(Jun 23, 2011 02:15 PM)Banksу Wrote:  I kind of get it (i think), well at least the first part... It's getting the amount of forms in a file?

you can get all forms of the .net file
and with showDialog. you see them one by one.

(Jun 23, 2011 02:15 PM)KingCobraXD Wrote:  I think he's using reflection to load the main form of an application. That way, you don't need to login....

no no no.
see what i coded.
i dont see here any 'methoodInfo'

(Jun 23, 2011 02:13 PM).bLaZeD Wrote:  I have no idea what this is supposed to do. Please explain more.

you can see all forms of any .net file.
and its allow you to pass on any login form.
There is an easy way to prevent this and i've done it with my keylogger. =)
It appears he is loading all forms in the executable. Which is why in a login/verify form you should pass a value to the main form to be used as a key.
I don't understand it =/

Here's VB.NET code (credits to Manager (I think) ):
Code
Private Sub GetAllForm(file As String)
    Dim asm = Assembly.Loadfile(file)
    Dim typeList = asm.GetTypes()
    Dim formList = New List(Of Form)()

    For i As Integer = 0 To typeList.Length - 1
        If typeList(i).IsClass AndAlso typeList(i).IsSubClassOf(GetType(form)) Then
            formList.add(TryCast(Activator.CreateInstance(typeList(i)), Form))
        End If
    Next
    For i As Integer = 0 To formList.Count - 1
        formList(i).ShowDialog()
    Next
End Sub
[Image: DIZMPqM.png]
(Jun 23, 2011 02:19 PM)KingCobraXD Wrote:  There is an easy way to prevent this and i've done it with my keylogger. =)

Doesn't obfuscation prevent Reflection??
Bitcoin Address: 1KQCBvevk1sA4wSj7gugv3sf5yjUygAzcv
(Jun 23, 2011 02:53 PM)Vysse Wrote:  Doesn't obfuscation prevent Reflection??

if it change the file to c \ c+ \ delphi and load the base code into memory.
but its not happen. 🤝
(Jun 23, 2011 02:57 PM)Manager Wrote:  if it change the file to c \ c+ \ delphi and load the base code into memory.
but its not happen. 🤝

No I know for a fact that certain obfuscation measures will prevent reflection based loading...
Bitcoin Address: 1KQCBvevk1sA4wSj7gugv3sf5yjUygAzcv
Ahh, now I understand. But, cant you do this with reflexil in reflector?
(Jun 23, 2011 03:05 PM)Vysse Wrote:  Everytime you touch your keyboard you make yourself look more like a skid...
Well, I didn't really mean that. I realize what the code does, but if you are trying to get past the main form I'm almost 100% positive you can edit it with reflexil.
(Jun 23, 2011 02:53 PM)Vysse Wrote:  Doesn't obfuscation prevent Reflection??

Hmmm..I'm actually not so sure about that. Anyways, you can just have the login form contain some boolean that states whether the user has logged in or not. When the main form loads, it will check the boolean. If it's false, it will exit. If not, it'll continue. That way, this trick wouldn't work at all...


Possibly Related Threads...
Thread / Author Replies Views Last Post
[Python] by SIM-4604643Mar 30, 2020 11:37 AM 4 161 Mar 30, 2020 11:37 AM
Last Post: Mohinder
[C#] by RickHTWDec 30, 2017 05:57 PM 5 392 Dec 30, 2017 05:57 PM
Last Post: RickHTW
[.NET] by CacheIsAFagOct 11, 2017 07:17 PM 5 231 Oct 11, 2017 07:17 PM
Last Post: webdev77