Accessing stack from heap.Why is this UnSafe?

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,

Accessing a block of memory in stack from Heap or viceversa,
is said to be unsafe and a potential security threat.

Please calrify why is this so.

ThankYou.
 
Manivannan.P said:
Hi,

Accessing a block of memory in stack from Heap or viceversa,
is said to be unsafe and a potential security threat.

Please calrify why is this so.

ThankYou.

The stack and things in the heap (unless pinned) can be moved by GC to
compact memory.
 
The stack and things in the heap (unless pinned) can be moved by GC to
compact memory.

The stack(s) itself isn't affected by GC so it will not move.

It's unsafe because direct manipulation of the stack opens up the risk
of buffer overrun/underrun security bugs and lets you violate type
safety.


Mattias
 
| Hi,
|
| Accessing a block of memory in stack from Heap or viceversa,
| is said to be unsafe and a potential security threat.
|
| Please calrify why is this so.
|
| ThankYou.

What exactly do you mean by "Accessing a block ... from Heap..."? Need some
more context here....

Willy.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Back
Top