Jump to content
Sign in to follow this  
laffo16

restricting commands

Recommended Posts

laffo16

hello! ok In my program, i have a section of autoit code which will be free for the customer edit, but i want to place restrictions on the functions & varibles which they can use to stop them from gathering othre important information within the script. can this be done? suggestions anyone?

Share this post


Link to post
Share on other sites
PsaltyDS

hello! ok In my program, i have a section of autoit code which will be free for the customer edit, but i want to place restrictions on the functions & varibles which they can use to stop them from gathering othre important information within the script. can this be done? suggestions anyone?

No. Put the user editable data in a separate place, i.e. and INI file or the registry.

:)


Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law

Share this post


Link to post
Share on other sites
laffo16

ok thanks, why would this not be recommended? is it not possible? i have determined the only varibles and functions to allow would be:

$playgroup

$tocall

$bb

$findmypos

$pot

makebet()

checkcall()

fold()

$firstact

Share this post


Link to post
Share on other sites
weaponx

Why aren't you just providing a GUI that limits what the users can do?

Share this post


Link to post
Share on other sites
laffo16

to give the user more freedom on how they can use the varibles allowed, by allowing them to write their own conditional statements.

Share this post


Link to post
Share on other sites
dinodod

Depending on what you are wanting, you can program those variables INTO your script so they are embedded in the code itself. INI and Reg keys are nice but easy to find and change. You *COULD* encrypt a file if you want to hold the variables outside.

Or design your GUI NOT to show those particular variables so the user doesn't have any idea of them in the 1st place.

ok thanks, why would this not be recommended? is it not possible? i have determined the only varibles and functions to allow would be:

$playgroup

$tocall

$bb

$findmypos

$pot

makebet()

checkcall()

fold()

$firstact


Digital Chaos - Life as we know it today.I'm a Think Tank. Problem is, my tank is empty.The Quieter you are, the more you can HearWhich would you choose - Peace without Freedom or Freedom without Peace?Digital Chaos Macgyver ToolkitCompletely Dynamic MenuSQLIte controlsAD FunctionsEXCEL UDFPC / Software Inventory UDFPC / Software Inventory 2GaFrost's Admin Toolkit - My main competitor :)Virtual SystemsVMWAREMicrosoft Virtual PC 2007

Share this post


Link to post
Share on other sites
laffo16

i've managed to restrict the creation of new varibles, in the users script. I'm hoping this will be enough. My problem now is that i need the said "users-editable-code.au3" to be included into the main compiled script each time it runs. The same way it is done when you run an include in an au3 file before it is compiled. is this at all possible? or how else can you go around importing au3 code into a compiled exe?

Share this post


Link to post
Share on other sites
laffo16

suggestions anyone? is this possible? if it isnt please let me know

Share this post


Link to post
Share on other sites
SmOke_N

/AutoIt3ExecuteScript


Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Share this post


Link to post
Share on other sites
laffo16

readup on /AutoIt3ExecuteScript, thanks for the suggestion but its not really what i need.

executing the users script seperatly brings me a hole lot of other problems. I have pretty

much given up on this search. i see no way of reading an *.au3 file and including its code

into my pre-compiled exe.... such as...

main.exe - >>

main program....

main program....

$code = fileread(editable.au3)

execute $code or include "editable.au3"

main program....

main program....

end main.exe <<

so when editable.au3 is changed, the main.exe does not need re-compiling with the update.

Share this post


Link to post
Share on other sites
SmOke_N

readup on /AutoIt3ExecuteScript, thanks for the suggestion but its not really what i need.

executing the users script seperatly brings me a hole lot of other problems. I have pretty

much given up on this search. i see no way of reading an *.au3 file and including its code

into my pre-compiled exe.... such as...

main.exe - >>

main program....

main program....

$code = fileread(editable.au3)

execute $code or include "editable.au3"

main program....

main program....

end main.exe <<

so when editable.au3 is changed, the main.exe does not need re-compiling with the update.

You're either going to have to "re-compile" it, or learn about injection... either way, it seems way more trouble than it's worth.

Edit:

Reading your list above... you say "Execute code or #inlude editable.au3"

I'm curious why /AutoIt3ExecuteScript won't work now?

1. Read Changes

2. Write File with changes

3. Execute new .au3 as a child process

4. Close parent if necessary

5. Now new child is parent.

Edited by SmOke_N

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Share this post


Link to post
Share on other sites
laffo16

i'm going to give it a shot SmOke_N, i think it just took a little time for the concept to settle in :)

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  

×