Solved

How do I recv/trns Carriage Return in CGI script written in C?

Posted on 1997-03-09
1
212 Views
Last Modified: 2013-12-25
Dear Sir/Ms.
     I just want to setup a CGI program(Written in C) which can change the password in the WWW interface.  And the CGI program accpept the Username, Old-Passwd and New-passwd, then it use fork() to generate a child process and create two pipe fdin/fdout to communicate the child process(the child process
is the telnet function on the destination host).  Then the child process use "passwd" command to change the passwd on the destination machine.  The program is working quite well under C shell.  But it really doesn't work under WWW interface, I think the reason is that httpd filters out all the Carriage Return so the command I issue from the parent can't reach the destination.

    Can you tell me how to receive and transmitt Carriage Return through httpd?
 What is  the Carriage Return turned into in the httpd?

     Thanks a lot.

    Please also send your reply to my E-mail box:

         mailto://hyjin@moon.bjnet.edu.cn

Yours,
Teddy
Mar 9, 1997
~
0
Comment
Question by:hyjin
1 Comment
 
LVL 1

Accepted Solution

by:
chump earned 0 total points
ID: 1827739
Carriage and linefeed are transmitted as %0D and %0A.

0

Featured Post

Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

Join & Write a Comment

If you get a (Blue Screen of Death), your system writes a small file called a minidump. Your first step is to make certain your computer is setup to record memory dumps. Right click My Computer, choose properties. Click on the advanced tab, an…
It is a general practice to get rid of old user profiles on a computer  in a LAN environment. As I have been working with a company in a LAN environment where users move from one place to some other place at times. This will make many user profil…
Learn the basics of strings in Python: declaration, operations, indices, and slicing. Strings are declared with quotations; for example: s = "string": Strings are immutable.: Strings may be concatenated or multiplied using the addition and multiplic…
In this seventh video of the Xpdf series, we discuss and demonstrate the PDFfonts utility, which lists all the fonts used in a PDF file. It does this via a command line interface, making it suitable for use in programs, scripts, batch files — any pl…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now