Linux Help
guides forums blogs
Home Desktops Distributions ISO Images Logos Newbies Reviews Software Support & Resources Linuxhelp Wiki

Welcome Guest ( Log In | Register )

Advanced DNS Management
New ZoneEdit. New Managment.


Sign Up Now
Reply to this topicStart new topic
> System(" ");, Using shell commands in cgi.
post Oct 17 2005, 01:59 PM
Post #1


Group: Members
Posts: 25
Joined: 12-October 04
Member No.: 3,935

I'm tring to write a prgram that I can input some text on my hosted web page, then display the text with the wall commande.
From a shell if i issue the command echo "hello world" | wall . all is good
If in my cgi (written in c/++) I can use system("mkdir"); it works. But if i try system("echo hello | wall"); it does not.

What am I doing wrong?

P.s. I know this is not a good idea for security issues .ie if the text was mail /etc/paswd/; hello world , but i want to be able to do this...
Go to the top of the page
+Quote Post
post Oct 18 2005, 12:45 PM
Post #2

RMS is my Hero

Group: Support Specialist
Posts: 782
Joined: 6-October 02
From: Trichy,INDIA
Member No.: 29

I cant give you the solution.I can only, give you the reason.

And the most probable one is, Apache user doesnt have persmissions to write to ttys.

I have never seen,such scripts.Can you post the whole script?

Hemant Kumar
user posted image
Go to the top of the page
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:


RSS Lo-Fi Version Time is now: 23rd March 2018 - 01:46 AM