Sign in to follow this  
Followers 0
DerrickFaria

Disable DEP in XP by editing the boot configuration File

9 posts in this topic

Ok so what i need to do is disable DEP on XP by replacing OptIn with AlwaysOff in the boot configuration file that is a hidden system file in the C:\ and for the life of me i Cant get it to work.

Please help

Thank you

Derrick

Share this post


Link to post
Share on other sites



Have you tried the help file?


[font="Comic Sans MS"]My code does not have bugs! It just develops random features.[/font]My Projects[list][*]Live Streaming (Not my project, but my edited version)[right]AutoIt Wrappers![/right][/list]Pure randomness[list][*]Small Minds.......................................................................................................[size="1"]Simple progress bar that changes direction at either sides.[/size][*]ChristmasIt AutoIt Christmas Theme..........................................................[size="1"]I WAS BOOOORED![/size][*]DriveToy..............................................................................................................[size="1"]Simple joke script. Trick your friends into thinking their computer drive is haywire![/size][/list]In Development[list][*]Your Background Task Organiser[*]AInstall Second Generation[/list]BEFORE POSTING ON THE FORUMS, TRY THIS:
%programfiles%/AutoIt3/autoit3.chm

Share this post


Link to post
Share on other sites

Ok so what i need to do is disable DEP on XP by replacing OptIn with AlwaysOff in the boot configuration file that is a hidden system file in the C:\ and for the life of me i Cant get it to work.

Please help

Thank you

Derrick

It's because it has hidden and system attribute !

See helpfile for change his attribute before modify it.


AutoIt 3.3.14.2 X86 - SciTE 3.6.0WIN 8.1 X64 - Other Example Scripts

Share this post


Link to post
Share on other sites

Okay so I am doing it a little differently now. I am able to bring up the boot.cfg file but i don't want to use the find and replace tool in notepad itself what I would like to do is have the script see the text and edit it then close and save but I an not finding any functions to do that in the help file so if you guys know of one i would really appreciate it.

Thanks again,

Derrick

Share this post


Link to post
Share on other sites

The decent way to disable this sort of security measure would be to prompt the user to disable it.

Off the top of my head I cannot think of a valid reason to discreetly disable it.

Perhaps you could educate me on that point.


AutoIt Absolute Beginners    Require a serial    Pause Script    Video Tutorials by Morthawt   ipify 

Monkey's are, like, natures humans.

Share this post


Link to post
Share on other sites

The decent way to disable this sort of security measure would be to prompt the user to disable it.

Off the top of my head I cannot think of a valid reason to discreetly disable it.

Perhaps you could educate me on that point.

I am making this script for a friend that is setting up 400 terminals across Cali to connect to a an Xray tech server and the user end of the software requires DEP to be disabled i think its kind of stupid but there is no way around it.

Share this post


Link to post
Share on other sites

"i think its kind of stupid but there is no way around it."

No kidding, windows xp running an xray macine has to be one on the stupidest things in the world.

You think the end user would just click the couple of buttons to turn it off.


AutoIt Absolute Beginners    Require a serial    Pause Script    Video Tutorials by Morthawt   ipify 

Monkey's are, like, natures humans.

Share this post


Link to post
Share on other sites

The Xp machines are not running the Xray machines they are in Doctors offices and are only connecting to the XRay Tech server. So the docs can review them and interact with the true Xray technicians.

Share this post


Link to post
Share on other sites

#9 ·  Posted (edited)

#include <file.au3>

OptIn_2_AlwaysOff()
If Not @error Then Run(@SystemDir & '\Notepad.exe ' & @HomeDrive & '\boot.ini')

Func OptIn_2_AlwaysOff()
    Local $array, $source = @HomeDrive & '\boot.ini'
    If Not FileExists($source) Then Return SetError(-1)
    FileSetAttrib($source, '-RASH')
    _FileReadToArray($source, $array)
    FileDelete($source)
    For $i = 1 To $array[0]
        If StringInStr($array[$i], 'OptIn') Then $array[$i] = StringReplace($array[$i], 'OptIn', 'alwaysoff')
        FileWriteLine($source, $array[$i])
    Next
    FileSetAttrib($source, '+RASH')
EndFunc

Edited by ripdad

"The mediocre teacher tells. The Good teacher explains. The superior teacher demonstrates. The great teacher inspires." -William Arthur Ward

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!


Register a new account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0