Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enable ASLR #16

Open
Dyras opened this issue Aug 21, 2017 · 4 comments
Open

Enable ASLR #16

Dyras opened this issue Aug 21, 2017 · 4 comments

Comments

@Dyras
Copy link

Dyras commented Aug 21, 2017

Greetings! It has come to my attention that SuperF4 does not have ASLR enabled. Is there a reason for this? If possible, could you enable it? It's one of two programs on my computer that isn't using ASLR.

@stefansundin
Copy link
Owner

Hi Dyras,

I haven't thought about ASLR, looks like support for it exists now in GCC with the flag --high-entropy-va. I'll definitely give it a try when I look into releasing the next version.

Thanks for the suggestion!

@rmenessec
Copy link

@stefansundin, would you consider adding a Visual Studio solution? That would make it easier for me—possibly other folks—to recompile the code on my own, and add Control Flow Guard, ASLR, and so forth.

For what it's worth, Visual Studio 2015 and now 2017 both have a "Community Edition" that's free-as-in-beer, and fully functional unless you need the Microsoft proprietary "team" features.

Thanks in advance.

@stefansundin
Copy link
Owner

I tried to use -Wl,--high-entropy-va and -Wl,--image-base,0x140000000 as reported on some websites to enable ASLR, but Process Explorer kept saying that it was disabled. It's hard to find information on the proper way to use it.

As for Visual Studio, I haven't given it a try yet.

@amroamroamro
Copy link

Visual Studio steps:

  • File > New > Project From Existing Code...
  • Select "Visual C++", browse to root folder and set name to "superf4", click Finish
  • Project > Properties > (All Configs & All Platforms) > Linker > Input
  • Add two additional dependencies: shlwapi.lib psapi.lib
  • In Solution Explorer, remove (not delete!) all files from project except: superf4.c & superf4.rc
    (rest are #included from these two, thus treated as external dependencies not files to compile directly)
  • Build

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants