How do I allow users to execute server-side batch files?

 
Post new topic   Reply to topic    Aprelium Forum Index -> General Questions
View previous topic :: View next topic  
Author Message
msmollison
-


Joined: 24 Feb 2004
Posts: 15

PostPosted: Thu Mar 18, 2004 4:08 am    Post subject: How do I allow users to execute server-side batch files? Reply with quote

I want a user to be able to click a link that will execute a batch file on my server, just like how a cgi file would work. I tried using cmd.exe as a CGI interpreter with extensions bat, but I get error 500 when i click on a .bat file link. Can anyone help me? I have heard that Apache will do this automatically for you...

My site is at msm33.hopto.org I have lost my Powered by Abyss logo, if anyone can link me to one I will put it up there...
Back to top View user's profile Send private message Send e-mail AIM Address MSN Messenger
TRUSTAbyss
-


Joined: 29 Oct 2003
Posts: 3752
Location: USA, GA

PostPosted: Thu Mar 18, 2004 6:52 am    Post subject: Reply with quote

All I can help you with is this

Back to top View user's profile Send private message Visit poster's website
Omar G
-


Joined: 21 Mar 2003
Posts: 34
Location: Honolulu, Hawai'i

PostPosted: Thu Mar 18, 2004 1:49 pm    Post subject: Reply with quote

Use Server side includes. Make a file called batch.shtml or whatever, and add a directive <!--#exec virtual="path to batch file" --> and the batch file should return its output, in raw text, to your page. Note, however, this is extremely risky to do on the open internet. SSI has absolutely no security as would a good CGI. People could spoof a url to your batch file and pass commands to it, such as "format C:", which would be really, really bad: it erases your harddrive...

- Omar G
Back to top View user's profile Send private message
aprelium
-


Joined: 22 Mar 2002
Posts: 6800

PostPosted: Thu Mar 18, 2004 6:01 pm    Post subject: Re: How do I allow users to execute server-side batch files? Reply with quote

msmollison,

Please contact support@aprelium.com to get a batch file wrapper. It will help you running your BAT files as any other CGI script.
_________________
Support Team
Aprelium - http://www.aprelium.com
Back to top View user's profile Send private message Send e-mail
iNaNimAtE
-


Joined: 05 Nov 2003
Posts: 2381
Location: Everywhere you're not.

PostPosted: Thu Mar 18, 2004 11:51 pm    Post subject: Reply with quote

Why can't you just use a CGI script instead?
_________________
Bienvenidos!
Back to top View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number
msmollison
-


Joined: 24 Feb 2004
Posts: 15

PostPosted: Fri Mar 19, 2004 2:40 am    Post subject: Reply with quote

Because I don't know CGI, but I know MS-DOS batch language, and I want to do some very specific tasks.
Back to top View user's profile Send private message Send e-mail AIM Address MSN Messenger
iNaNimAtE
-


Joined: 05 Nov 2003
Posts: 2381
Location: Everywhere you're not.

PostPosted: Sun Mar 21, 2004 5:49 am    Post subject: Reply with quote

Too bad. I'de start reading up on perl, it will get you farther.
_________________
Bienvenidos!
Back to top View user's profile Send private message Send e-mail Visit poster's website AIM Address Yahoo Messenger MSN Messenger ICQ Number
Display posts from previous:   
Post new topic   Reply to topic    Aprelium Forum Index -> General Questions All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB phpBB Group