Base address Programming Software Development by shouvik.d …i have a need to use the Rva+Base address of all the methods available in a class …but say if u don't have the address available so relocation takes place hence the …is there any way of obtaining the base address or the load address of a process. if at all…viable solution then can i obtain the current address from the mangled names like [b]?show@disp… Re: Base address Programming Software Development by shouvik.d I think you didn't get my question correctly. I need the Load address of a process. So that i can calculate the [B]Rva+Base[/B] address please refer to the links i'd provided in my posts Re: Base address Programming Software Development by Ancient Dragon You want the address of a function? [code] int foo() { // blabla return something; } // pointer to the function int (*fn)(); // set pointer fn = foo; [/code] You can also get pointers to class methods. I have not used them so I'm not sure how they work. Getting base address of a process Programming Software Development by yoni0505 …is windows 7 64bit) Using cheat engine I found the base address of the variable, but it changes every time I …What do I need to do to find out the base address automatically? Does it have something to do with the executable… base address? Here's my code: #include <windows.h> #include… Re: Getting base address of a process Programming Software Development by mitrmkar …> I found the base address of the variable, but …that your Minesweeper has been compiled with [Address space layout randomization](http://msdn.microsoft.com…/bb384887.aspx) enabled, meaning that the address of the variable will continue to keep … /headers minesweeper.exe` and look for `Dynamic Base` under `OPTIONAL HEADER VALUES` as in the… Re: Getting base address of a process Programming Software Development by BobS0327 …/ms682489%28v=vs.85%29.aspx) function to get the base address from the [MODULEENTRY32](http://msdn.microsoft.com/en-us/library… point. You will need to add an offset to the base address to where your data resides. Finally, execute your ReadProcessMemory at… Re: Finding base address of struct Programming Software Development by doug65536 …some pointer arithmetic. It is impossible to get the base of the structure in C (or C++) without knowing…p - memberofs); cout << "The base address is " << base; } [/code] If you're cheating that much… you might as well just say &Check is the base address. Re: Finding base address of struct Programming Software Development by mike_2000_17 >>Is it impossible to find the base address using two of these info?? "[B]Insanity[/B]: doing … a different answer? The answer is clear, to find the base address of the struct, you need to know which member that… you don't know which member it is, only its address, then it is IMPOSSIBLE to find the base address of the struct. Re: Getting base address of a process Programming Software Development by Ancient Dragon …()](http://www.daniweb.com/software-development/cpp/threads/421828/getting-base-address-of-a-process) more carefully and follow the examples links… Re: Getting base address of a process Programming Software Development by AceStryker In a PE file the base address is always in the same place the Optional Header, in the windows structures [IMAGE_OPTIONAL_HEADER](http://msdn.microsoft.com/en-us/library/windows/desktop/ms680339(v=vs.85).aspx) it is known as **AddressOfEntryPoint**, you just need to fill the structure and take it... Re: Finding base address of struct Programming Software Development by marirs07 …, } test; Void Func(int *ptr) { /* How will you get the base address of the structure*/ You know only the name of the…]The problem is quite clear....I need to find the base address of the struct .I know that the name is Check… Re: Finding base address of struct Programming Software Development by marirs07 …, } Check; Void Func(int *ptr) { /* How will you get the base address of the structure*/ You know only the name of the… a function to another function how will you get the base address of the structure itself. You Know: 1) Only the name… Re: Finding base address of struct Programming Software Development by marirs07 Ya ur rite!!! i know the address of one of its members and a structure name say … structure name i.e cook ,i need to find the base address of the structure in that function[/QUOTE] Waiting for d… Finding base address of struct Programming Software Development by marirs07 Hi all, How to find the base address of a structure ,just by knowing the name of the structure and a address of one of its members. Thanks in advance Re: Finding base address of struct Programming Software Development by marirs07 The instance name is not known!!!! Only the name of the struct(breakfasr) and address of one of its members say &one.eggs is known.Using these two data the base address needs to be found out!!! Re: Finding base address of struct Programming Software Development by Moschops If it will always be &test.b passed in, you can make a struct of your own inside the function, calculate the difference between the address of your new struct's base address and its b member, and then apply that difference to the value passed in. Re: Finding base address of struct Programming Software Development by mike_2000_17 >>The problem is quite clear....I need to find the base address of the struct .I know that the name is Check and the address of one of the member is p And the answer is clear: [B]IT IS IMPOSSIBLE![/B] Re: Finding base address of struct Programming Software Development by marirs07 But what all can we do using a structure name and the address of one of its members??!! Is it impossible to find the base address using two of these info?? Re: Base address Programming Software Development by Ancient Dragon The people as codeproject.com seems to have answered your question quite adequately. I see no point in rehashing something that was already posted over there. Re: Base address Programming Software Development by shouvik.d you needn't have taken pains to post this too. Re: Base address Programming Software Development by shouvik.d [quote=Ancient Dragon;305631]The people as codeproject.com seems to have answered your question quite adequately. I see no point in rehashing something that was already posted over there.[/quote] Firstly though this is a follow up of the previous thread but it's nowhere near to rehashing... secondly my private access is done whereby I did not … Re: Finding base address of struct Programming Software Development by doug65536 … *p and just say &Check is the base! 3) From a raw address it is impossible to determine a struct offset… without knowing what member it is. 4) Without an offset, calculating the base Re: Finding base address of struct Programming Software Development by dospy … is, they want to find out the address of a structure by knowing the address of one of it's members for…] struct { int _a; // let's assume that this int's address is 0x02F48C } Check; // how do we find out the… address of Check without using '&Check'? [/CODE] i've heard … Re: Finding base address of struct Programming Software Development by dospy you basically can't 'find out the address' of something that does not exist, you need an instance of the given class/struct to take out it's address when you say, for example [CODE] struct MyStruct { int someVarName; };[/CODE] you don't declare anything(you just Define), thus you can't take it's address unless you do what Moschops showed you. Re: Finding base address of struct Programming Software Development by dospy … Check, Check2, Check3 etc before the semicolon[/CODE] taking the address is rather simple from now; ex: [CODE] #include <…char c; } Check; int main( ) { std::cout << "Address of the unnamed structure instance named 'Check': " <<… 0; } [/CODE] so, if you need to pass the address to the function, just use '&Check'; Re: Finding base address of struct Programming Software Development by Fbody … Check2, Check3 etc before the semicolon[/CODE] taking the address is rather simple from now; ex: [CODE] #include… Check; int main( ) { std::cout << "Address of the unnamed structure instance named 'Check': " <<… } [/CODE] so, if you need to pass the address to the function, just use '&Check';[/QUOTE] I… Re: Finding base address of struct Programming Software Development by marirs07 :) The thing is that we dont know that the address p is address of b,then how can we put the member name b in offsetof() i.e inside the function i know only the name of the structure (A ,in this case) and address *p. Re: Finding base address of struct Programming Software Development by vijayan121 > The thing is that we dont know that the address p is address of b Then there is [B]no way[/B] to reliably determine the address of the struct object. Re: Finding base address of struct Programming Software Development by marirs07 No,any address of members can be passed in.We dont know that the address is of b. Thanks for ur reps!!! Re: Finding base address of struct Programming Software Development by Moschops This gives the address of an instance of the structure named [B]one[/B], of type [B]breakfast[/B]. I just need to know the name of it - [B]one[/B]. [CODE]#include <iostream> struct breakfast { int eggs; int beans; }; int main() { breakfast one; std::cout << &one; return 0; }[/CODE]