Questions tagged [local-variables]

Local variables are variables which scope is limited to the block they were declared in. The opposite is global variable which can be accessible anywhere in the code.

Filter by
Sorted by
Tagged with
0 votes
0 answers
30 views

Is there any way to create alias/variable for memory-related value in Radare 2?

I wonder if it is possible in r2 to make alias for the value that repeats itself many times. For instance: I want to have an alias for rbp + rax - 0x1020 to be named as cwd[i]. Can it be done? I ...
satk0's user avatar
  • 101
1 vote
0 answers
555 views

What is happening with this *param_1?

I am a bit of a starter, so bear with me as I can't find the answer through Google (a common thing in Ghidra work I noticed so far). I have a function that seems to read like it is a Constructor. But ...
Smileynator's user avatar
2 votes
0 answers
61 views

Getting all instances of Local type in Ida

I create a local type in Ida and put in some places this local type. How can I got all the references to dhat Local type?
yfr24493AzzrggAcom's user avatar
0 votes
1 answer
1k views

Find out the name of constants and var in IDA pro

I'm trying to search with IDA pro constants of type "#define SIZE 100" and normal local variables from a gcc-compiled binary file. I know there are a lot of open threads on the subject but I ...
Michael's user avatar
0 votes
1 answer
2k views

How to watch a function's local variable in GDB?

I'm reversing a 64bit binary with gdb & peda and I've identified a function of interest (probably encoding user input). I want to watch the function interesting's local variable arg1. How can I ...
ChocolateOverflow's user avatar
1 vote
2 answers
3k views

Local variables and addition not shown in Ghidra

I am having some troubles with my learning of Assembly and reverse engineering. Specifically, I am learning about Global vs Local variables. For Global variables I have managed to get insights in ...
Rebegin's user avatar
  • 87
4 votes
2 answers
764 views

How can I find my variables in the running process?

I'm new with reversing and I did the following experiment just intent to help my understanding. I created a very simple 64-bit c++ program. #include <iostream> #include <string> using ...
Just a learner's user avatar
1 vote
0 answers
264 views

IDA Pro 7.0 showing incorrect LOCALS in pseudocode view

Whenever I debug something and I switch to pseudocode and then rename some of the "variables" that IDA Pro creates, the values shown in the LOCALS window don't match what the actual values of those ...
alexandernst's user avatar
2 votes
1 answer
246 views

There is any way to see the subroutine local variables values and who actually access them?

I know that it exists gdb, but i'm talking about windows, i would like know if there is any way to see who access to current stackframe of a specified variable on an X subroutine... i've tried using ...
MindLerp's user avatar
  • 197
2 votes
1 answer
476 views

Dolphin Emulator Android port modifications

I am modifying the Dolphin Emulator Alpha for android, but I'm having some trouble with a string in it's smali code. The value I am having trouble with is dolphin-emu, it is the name of the folder ...
Mr. Mendelli's user avatar
0 votes
2 answers
984 views

How does this local var get assigned?

I'm using IDA PRO to disassemble a function, which produces a control flow that looks like this: start_IE proc near Buffer= dword ptr -230h var_22C= byte ptr -22Ch hFile= dword ptr -30h hInternet= ...
the_endian's user avatar
  • 1,800
2 votes
0 answers
917 views

How can I control local variable ordering on stack in gcc?

I am writing a reversing challenge where I need to seed a bug. It's important to have a particular ordering of local variable on stack in a method. However, gcc seems to shuffle those around. How can ...
sherlock's user avatar
  • 1,351
0 votes
2 answers
3k views

Obtaining memory locations of local variables

For ELF binaries on Linux, if the executable is not stripped, it is possible to recover memory locations of location variables in the form of relative addresses to stack/frame pointer? As an example, ...
sherlock's user avatar
  • 1,351
1 vote
1 answer
372 views

Variable liveness analysis on binaries

I want to detect all the variables live at any instruction/address in a binary. By variable, I refer to both global as well as function local variables. In other words, given a Linux ELF and a virtual ...
sherlock's user avatar
  • 1,351
2 votes
1 answer
162 views

Tracing variable access/usage instructions

There is a great little closed-source freeware Windows program (written in Delphi) that I have been using for years. WinBar shows a little bar above the TaskBar which gives some system information and ...
Synetech's user avatar
  • 121
0 votes
1 answer
752 views

How to map a function argument to local variable?

Well, I've got an function that the pseudo code looks like: void d4l_auxadc_cali_unlocked_ioctl() { unsigned int v0; // r1@1 unsigned int v1; // r7@1 ... However, I am aware that the ...
dr4lamb's user avatar
4 votes
1 answer
15k views

IDA PRO repairing stack variables / local variables hex-rays with arrays and proper types / structures any scripts/plugins?

IDA PRO's Hex-Ray gives me these variables. void *v7; // esp@1 const char *v8; // ebx@1 PLAYER *v9; // ebp@1 int v10; // edi@5 PLAYER *v11; // edx@6 int v12; // ecx@9 int v13; // esi@17 ...
SSpoke's user avatar
  • 759