Your best friend for file transfer.

Fetch application logoFetch

Permissions Problem (4 posts)

  • Started 18 years ago by knoxtenn
  • Latest reply 18 years ago from Scott McGuire
  • knoxtenn Member

    I have uploaded cgi scripts (FormMail.cgi) using 755 as the permissions. However, the email form will not work. I get an error message saying:

    Premature end of script headers

    Any ideas?

    Posted 18 years ago #

  • Scott McGuire Administrator

    Hi,

    Here's one thing to try, assuming you are using Fetch 5:

    * Connect to the server.
    * In Fetch's Remote menu, choose Text from the Format submenu.
    * Upload your cgi script(s) again.
    * Set the permissions again.
    * Test the script again.

    If that does not fix the problem, could you please choose Fetch Transcript from the Window menu, copy the contents of the transcript window, and paste them here? We'll take a look and try to figure out what's going on.

    Thanks,

    Scott McGuire
    Fetch Softworks

    Posted 18 years ago #

  • knoxtenn Member

    That fixed the FormMail.cgi. However, the sim.pl and related files still won't work. Here is the transcript:

    PWD
    257 "/cgi-bin" is current directory.
    SIZE FormMail.cgi
    213 30034
    MDTM FormMail.cgi
    213 20051229024002
    PASV
    227 Entering Passive Mode (68,178,197,200,220,91).
    RETR FormMail.cgi
    150 Opening ASCII mode data connection for FormMail.cgi (30034 bytes)
    226 Transfer complete.
    PWD
    257 "/cgi-bin" is current directory.
    SIZE FormMail.cgi
    213 30034
    MDTM FormMail.cgi
    213 20051229024002
    PASV
    227 Entering Passive Mode (68,178,197,200,220,100).
    RETR FormMail.cgi
    150 Opening ASCII mode data connection for FormMail.cgi (30034 bytes)
    226 Transfer complete.
    DELE FormMail.cgi
    250 DELE command successful
    DELE sim.pl
    250 DELE command successful
    DELE SimHMAC.pm
    250 DELE command successful
    DELE SimLib.pm
    250 DELE command successful
    PASV
    227 Entering Passive Mode (68,178,197,200,220,118).
    STOR FormMail.cgi
    150 Opening ASCII mode data connection for FormMail.cgi
    226 Transfer complete.
    Upload complete at 12/28/05 9:44:13 PM
    SITE CHMOD 755 FormMail.cgi
    200 SITE CHMOD command successful
    PWD
    257 "/cgi-bin" is current directory.
    TYPE A
    200 Type set to A
    PASV
    227 Entering Passive Mode (68,178,197,200,220,119).
    LIST
    150 Opening ASCII mode data connection for file list
    -rwxr-xr-x 1 mtns1 psacln 29285 Dec 29 02:45 FormMail.cgi
    226-Transfer complete.
    226 Quotas off
    PASV
    227 Entering Passive Mode (68,178,197,200,220,124).
    STOR sim.pl
    150 Opening ASCII mode data connection for sim.pl
    226 Transfer complete.
    Upload complete at 12/28/05 9:44:49 PM
    PASV
    227 Entering Passive Mode (68,178,197,200,220,125).
    STOR SimHMAC.pm
    150 Opening ASCII mode data connection for SimHMAC.pm
    226 Transfer complete.
    Upload complete at 12/28/05 9:44:49 PM
    PASV
    227 Entering Passive Mode (68,178,197,200,220,126).
    STOR SimLib.pm
    150 Opening ASCII mode data connection for SimLib.pm
    226 Transfer complete.
    Upload complete at 12/28/05 9:44:49 PM
    SITE CHMOD 755 sim.pl
    200 SITE CHMOD command successful
    PWD
    257 "/cgi-bin" is current directory.
    TYPE A
    200 Type set to A
    PASV
    227 Entering Passive Mode (68,178,197,200,220,127).
    LIST
    150 Opening ASCII mode data connection for file list
    -rwxr-xr-x 1 mtns1 psacln 29285 Dec 29 02:45 FormMail.cgi
    -rw-r--r-- 1 mtns1 psacln 10428 Dec 29 02:46 SimHMAC.pm
    -rw-r--r-- 1 mtns1 psacln 2048 Dec 29 02:46 SimLib.pm
    -rwxr-xr-x 1 mtns1 psacln 2545 Dec 29 02:46 sim.pl
    226-Transfer complete.
    226 Quotas off
    SITE CHMOD 755 SimHMAC.pm
    200 SITE CHMOD command successful
    PWD
    257 "/cgi-bin" is current directory.
    TYPE A
    200 Type set to A
    PASV
    227 Entering Passive Mode (68,178,197,200,220,130).
    LIST
    150 Opening ASCII mode data connection for file list
    -rwxr-xr-x 1 mtns1 psacln 29285 Dec 29 02:45 FormMail.cgi
    -rwxr-xr-x 1 mtns1 psacln 10428 Dec 29 02:46 SimHMAC.pm
    -rw-r--r-- 1 mtns1 psacln 2048 Dec 29 02:46 SimLib.pm
    -rwxr-xr-x 1 mtns1 psacln 2545 Dec 29 02:46 sim.pl
    226-Transfer complete.
    226 Quotas off
    SITE CHMOD 755 SimLib.pm
    200 SITE CHMOD command successful
    PWD
    257 "/cgi-bin" is current directory.
    TYPE A
    200 Type set to A
    PASV
    227 Entering Passive Mode (68,178,197,200,220,133).
    LIST
    150 Opening ASCII mode data connection for file list
    -rwxr-xr-x 1 mtns1 psacln 29285 Dec 29 02:45 FormMail.cgi
    -rwxr-xr-x 1 mtns1 psacln 10428 Dec 29 02:46 SimHMAC.pm
    -rwxr-xr-x 1 mtns1 psacln 2048 Dec 29 02:46 SimLib.pm
    -rwxr-xr-x 1 mtns1 psacln 2545 Dec 29 02:46 sim.pl
    226-Transfer complete.
    226 Quotas off
    PWD
    257 "/cgi-bin" is current directory.
    PWD
    257 "/cgi-bin" is current directory.
    PWD
    257 "/cgi-bin" is current directory.
    PWD
    257 "/cgi-bin" is current directory.
    SITE CHMOD 777 SimLib.pm
    200 SITE CHMOD command successful
    PWD
    257 "/cgi-bin" is current directory.
    TYPE A
    200 Type set to A
    PASV
    227 Entering Passive Mode (68,178,197,200,220,185).
    LIST
    150 Opening ASCII mode data connection for file list
    -rwxr-xr-x 1 mtns1 psacln 29285 Dec 29 02:45 FormMail.cgi
    -rwxr-xr-x 1 mtns1 psacln 10428 Dec 29 02:46 SimHMAC.pm
    -rwxrwxrwx 1 mtns1 psacln 2048 Dec 29 02:46 SimLib.pm
    -rwxr-xr-x 1 mtns1 psacln 2545 Dec 29 02:46 sim.pl
    226-Transfer complete.
    226 Quotas off
    SITE CHMOD 777 SimHMAC.pm
    200 SITE CHMOD command successful
    PWD
    257 "/cgi-bin" is current directory.
    TYPE A
    200 Type set to A
    PASV
    227 Entering Passive Mode (68,178,197,200,220,189).
    LIST
    150 Opening ASCII mode data connection for file list
    -rwxr-xr-x 1 mtns1 psacln 29285 Dec 29 02:45 FormMail.cgi
    -rwxrwxrwx 1 mtns1 psacln 10428 Dec 29 02:46 SimHMAC.pm
    -rwxrwxrwx 1 mtns1 psacln 2048 Dec 29 02:46 SimLib.pm
    -rwxr-xr-x 1 mtns1 psacln 2545 Dec 29 02:46 sim.pl
    226-Transfer complete.
    226 Quotas off
    SITE CHMOD 777 sim.pl
    200 SITE CHMOD command successful
    PWD
    257 "/cgi-bin" is current directory.
    TYPE A
    200 Type set to A
    PASV
    227 Entering Passive Mode (68,178,197,200,220,190).
    LIST
    150 Opening ASCII mode data connection for file list
    -rwxr-xr-x 1 mtns1 psacln 29285 Dec 29 02:45 FormMail.cgi
    -rwxrwxrwx 1 mtns1 psacln 10428 Dec 29 02:46 SimHMAC.pm
    -rwxrwxrwx 1 mtns1 psacln 2048 Dec 29 02:46 SimLib.pm
    -rwxrwxrwx 1 mtns1 psacln 2545 Dec 29 02:46 sim.pl
    226-Transfer complete.
    226 Quotas off
    SITE CHMOD 755 sim.pl
    200 SITE CHMOD command successful
    PWD
    257 "/cgi-bin" is current directory.
    TYPE A
    200 Type set to A
    PASV
    227 Entering Passive Mode (68,178,197,200,220,193).
    LIST
    150 Opening ASCII mode data connection for file list
    -rwxr-xr-x 1 mtns1 psacln 29285 Dec 29 02:45 FormMail.cgi
    -rwxrwxrwx 1 mtns1 psacln 10428 Dec 29 02:46 SimHMAC.pm
    -rwxrwxrwx 1 mtns1 psacln 2048 Dec 29 02:46 SimLib.pm
    -rwxr-xr-x 1 mtns1 psacln 2545 Dec 29 02:46 sim.pl
    226-Transfer complete.
    226 Quotas off
    SITE CHMOD 755 SimHMAC.pm
    200 SITE CHMOD command successful
    PWD
    257 "/cgi-bin" is current directory.
    TYPE A
    200 Type set to A
    PASV
    227 Entering Passive Mode (68,178,197,200,220,194).
    LIST
    150 Opening ASCII mode data connection for file list
    -rwxr-xr-x 1 mtns1 psacln 29285 Dec 29 02:45 FormMail.cgi
    -rwxr-xr-x 1 mtns1 psacln 10428 Dec 29 02:46 SimHMAC.pm
    -rwxrwxrwx 1 mtns1 psacln 2048 Dec 29 02:46 SimLib.pm
    -rwxr-xr-x 1 mtns1 psacln 2545 Dec 29 02:46 sim.pl
    226-Transfer complete.
    226 Quotas off
    SITE CHMOD 755 SimLib.pm
    200 SITE CHMOD command successful
    PWD
    257 "/cgi-bin" is current directory.
    TYPE A
    200 Type set to A
    PASV
    227 Entering Passive Mode (68,178,197,200,220,201).
    LIST
    150 Opening ASCII mode data connection for file list
    -rwxr-xr-x 1 mtns1 psacln 29285 Dec 29 02:45 FormMail.cgi
    -rwxr-xr-x 1 mtns1 psacln 10428 Dec 29 02:46 SimHMAC.pm
    -rwxr-xr-x 1 mtns1 psacln 2048 Dec 29 02:46 SimLib.pm
    -rwxr-xr-x 1 mtns1 psacln 2545 Dec 29 02:46 sim.pl
    226-Transfer complete.
    226 Quotas off
    PWD
    257 "/cgi-bin" is current directory.

    Originally posted by ScottMcGuire:

    Hi,

    Here's one thing to try, assuming you are using Fetch 5:

    * Connect to the server.
    * In Fetch's Remote menu, choose Text from the Format submenu.
    * Upload your cgi script(s) again.
    * Set the permissions again.
    * Test the script again.

    If that does not fix the problem, could you please choose Fetch Transcript from the Window menu, copy the contents of the transcript window, and paste them here? We'll take a look and try to figure out what's going on.

    Thanks,

    Scott McGuire
    Fetch Softworks

    Posted 18 years ago #

  • Scott McGuire Administrator

    Hi,

    Thanks for posting the transcript. It looks like Fetch is uploading the files correctly now, so there is probably some problem in the cgi or related file's code.

    Unfortunately, we are not CGI experts and don't have any suggestions in that regard, sorry.

    By the way, if you make sure that your cgi files have Unix line endings when you're editing them on your Mac, you will probably not need to switch Fetch to use the Text upload format (you can just use the default Automatic format).

    Thanks,

    Scott McGuire
    Fetch Softworks

    Posted 18 years ago #

Reply

  • Or nickname, if you prefer.
  • This will be kept confidential.
  • This is to ensure that you’re a person, not a spambot.