danix
Goto Top

cgi exe im cgi Verzeichnis

Hallo ich habe den folgenden Quelltext von meinem Telefonanlagenhersteller bekommen:
Content-type: text/html

<html>

<body background="images/bgcolor_3.gif">  

<table border="0" width="100%">  
  <tr>
    <td width="56%" align="left" height="42"><p align="center"><big><big><big><font face="Comic Sans MS"><strong>Telefonverbindung herstellen</strong></font></big></big></big></td>  
  </tr>
</table>

<hr>

</script><!--webbot BOT="GeneratedScript" PREVIEW=" " startspan --><script Language="JavaScript"><!-- 
function FrontPage_Form1_Validator(theForm)
{

  var checkOK = "0123456789-"; 
  var checkStr = theForm.LOCALPHONE.value;
  var allValid = true;
  var decPoints = 0;
  var allNum = ""; 
  for (i = 0;  i < checkStr.length;  i++)
  {
    ch = checkStr.charAt(i);
    for (j = 0;  j < checkOK.length;  j++)
      if (ch == checkOK.charAt(j))
        break;
    if (j == checkOK.length)
    {
      allValid = false;
      break;
    }
    allNum += ch;
  }
  if (!allValid)
  {
    alert("Please enter only digit characters in the \"LOCALPHONE\" field."); 
    theForm.LOCALPHONE.focus();
    return (false);
  }

  var checkOK = "0123456789-"; 
  var checkStr = theForm.PHONENUMBER2.value;
  var allValid = true;
  var decPoints = 0;
  var allNum = ""; 
  for (i = 0;  i < checkStr.length;  i++)
  {
    ch = checkStr.charAt(i);
    for (j = 0;  j < checkOK.length;  j++)
      if (ch == checkOK.charAt(j))
        break;
    if (j == checkOK.length)
    {
      allValid = false;
      break;
    }
    allNum += ch;
  }
  if (!allValid)
  {
    alert("Please enter only digit characters in the \"PHONENUMBER2\" field."); 
    theForm.PHONENUMBER2.focus();
    return (false);
  }
  return (true);
}
//--></script><!--webbot BOT="GeneratedScript" endspan --><form ACTION="/cgi-bin/cgiexe" name="FrontPage_Form1"  method=post onsubmit="return FrontPage_Form1_Validator(this)" >  
    <table width="970" height="101">  
    <INPUT TYPE=hidden VALUE="makeanswercall" NAME="Action" >  
    <INPUT TYPE=hidden VALUE="makecallResult.htm" NAME="HTMLFILE" >       
    <INPUT TYPE=hidden VALUE="<%=CTIUSERNAME%>" NAME="CTIUSERNAME" >  
    <INPUT TYPE=hidden VALUE="<%=CTIPASSWORD%>" NAME="CTIPASSWORD" >  
    <tr>
      <td width="334" height="24"><font face="Comic Sans MS">Ihre Telefon-Nummer:</font></td>  

      <td width="153" height="24"><!--webbot bot="Validation" 
        S-Data-Type="Integer" S-Number-Separators="x" --><input TYPE="text" SIZE="15" NAME="LOCALPHONE" value="<%=LOCALPHONE%>"> </td>  
      <td width="230" height="24"></td>  
      <td width="184" height="24"></td>  
      <td width="226" height="24"></td>  
    </tr>
    <tr>
      <td width="334" height="19"><font face="Comic Sans MS">fremde Telelefon Nummer:</font></td>  
      <td width="153" height="19"><!--webbot bot="Validation" 
        S-Data-Type="Integer" S-Number-Separators="x" --><input TYPE="text" SIZE="15" NAME="PHONENUMBER2"> </td>  

      <td width="230" height="19"></td>  
      <td width="184" height="19"></td>  
      <td width="226" height="19"></td>  
    </tr>
    <tr>
      <td width="230" height="46"><input TYPE="submit" VALUE="Verbindung herstellen   "> <br>  
      </td>
      <td width="184" height="46"></td>  

      <td width="226" height="46"></td>  
    </tr>
  </table>
</form>

<hr>
</body>
</html>
Dies ruft ja die /cgi-bin/cgiexe auf, welche ich auch in das cgi-bin verzeichnis kopiert habe. Entweder heisst es aber dann dass die Datei nicht gefunden wird, oder dass die Seite nicht angezeigt werden kann.

Hat jemand eine Idee?

Danke
Gruß
danix

Content-Key: 67979

Url: https://administrator.de/contentid/67979

Ausgedruckt am: 19.03.2024 um 11:03 Uhr

Mitglied: DerBiba
DerBiba 05.09.2007 um 20:33:21 Uhr
Goto Top
Hey danix,

Ideen haben wir immer. Was uns, besonders mir, im Moment allerdings fehlt, sind wichtige Randinfos zu deinem so noch unverständlichen Problem.

Ich vermute mal, du lässt einen Apache laufen und hostest unter diesem die Webseite. Wenn dem so ist, wäre ein Blick in deine Apache conf sehr hilfreich, da dieser nämlich von Haus aus keine exe ausführt. Das muss man ihm erst einmal erlauben. Dann sollte diese exe natürlich auch im für den Apache definierten Verzeichnis für cgi liegen. Zudem muss dann evtl. auch noch der Quelltext deiner Webseite auf dieses cgi Verzeichnis angepasst werden.

Und überhaupt und sowieso interessiert mich mal, was mit oder durch die Website passieren soll ?

VG, Biba
Mitglied: danix
danix 05.09.2007 um 21:17:13 Uhr
Goto Top
Hi! Danke für die schnelle Antwort. Richtig vermutet es läuft der Apache Server auf nem Windows Server (xampp) - was ich damit vor habe? also das ganze ist eine Intranetseite im Unternehmen, auf der es eine CTI funktion geben soll. Also Klick auf die Nummer und damit Wahl der Nummer. Das gepostete ist das Testscript des CTI Anbieters, um zu testen ob das ganze funktioniert ...

ich werde morgen mal in die apache Datei rein schauen.

Der Verweis auf /cgi-bin/.....exe müsste aber doch korrekt sein, oder muss es da heißen ../cgi-bin weil die Seite die das Script aufruft unter /htdocs liegt?

Gruß
danix
Mitglied: 13100
13100 05.09.2007 um 23:31:15 Uhr
Goto Top
ich geh mal davon aus cgi.exe is dein exe-file, fehlt da nich irgendwie
der punkt für die erweiterung im sourcecode?
Mitglied: DerBiba
DerBiba 05.09.2007 um 23:39:10 Uhr
Goto Top
Das mit dem Verweis sehen wir dann, wenn ich die conf kenne face-smile

Achja, den xamp setzt du aber nur intern ein, ja? Der ist für einen realen Betrieb gar nicht gedacht und teilweise "löchrig", sprich der ist für Entwickler usw. gedacht, die mal eben schnell was testen wollen aber keine Zeit und/oder Lust haben, SQL, PHP etcpp zu installieren. Ist also ne reine Testumgebung !

Biba
Mitglied: DerBiba
DerBiba 05.09.2007 um 23:44:21 Uhr
Goto Top
Oh ja, gut gesehen Angeldust. Wenigstens hast du dir die Mühe gemacht den QC durchzugehen face-smile
Mitglied: danix
danix 06.09.2007 um 09:11:46 Uhr
Goto Top
Ja das ist "NUR" im Intranet, mehr nicht.

Aber das mit der exe hat mich auch schon gewundert. Die Datei die im cgi-bin Verzeichnis liegt heißt "cgiexe.exe". Wäre der Hammer wenn im Test Quelltext des Herstellers der da einige 1000 Euros verlangt ein Fehler drin wäre. Die Anleitung zur Implementierung ist mit "Kopieren Sie die exe in das cgi-bin Verzeichnis" ohnehin ein Witz.

Viele Grüße
danix
Mitglied: danix
danix 06.09.2007 um 10:52:27 Uhr
Goto Top
Ich poste hier jetzt mal noch meine httpd.conf (natürlich ohne Comments), welche ich nach meiner Meinung so weit bearbeitet habe, dass es gehen müsste. Leider bietet er mir trotzd er addhandler cgi-script .exe Erweiterung nur die exe zum Download an. Hat noch jemand eine Idee? ja gut ich weiß "DerBiba" dass ihr immer Ideen habt, darum frag ich ja face-wink

ThreadsPerChild 250
MaxRequestsPerChild  0

ServerRoot "C:/xampp/apache"  

Listen 80

LoadModule actions_module modules/mod_actions.so
LoadModule alias_module modules/mod_alias.so
LoadModule asis_module modules/mod_asis.so
LoadModule auth_basic_module modules/mod_auth_basic.so
LoadModule authn_default_module modules/mod_authn_default.so
LoadModule authn_file_module modules/mod_authn_file.so
LoadModule authz_default_module modules/mod_authz_default.so
LoadModule authz_groupfile_module modules/mod_authz_groupfile.so
LoadModule authz_host_module modules/mod_authz_host.so
LoadModule authz_user_module modules/mod_authz_user.so
LoadModule cgi_module modules/mod_cgi.so
LoadModule dav_module modules/mod_dav.so
LoadModule dav_fs_module modules/mod_dav_fs.so
LoadModule dir_module modules/mod_dir.so
LoadModule env_module modules/mod_env.so
LoadModule include_module modules/mod_include.so
LoadModule info_module modules/mod_info.so
LoadModule isapi_module modules/mod_isapi.so
LoadModule ldap_module modules/mod_ldap.so
LoadModule log_config_module modules/mod_log_config.so
LoadModule mime_module modules/mod_mime.so
LoadModule negotiation_module modules/mod_negotiation.so
LoadModule setenvif_module modules/mod_setenvif.so
LoadModule status_module modules/mod_status.so
LoadModule ssl_module modules/mod_ssl.so

LoadModule autoindex_color_module modules/mod_autoindex_color.so


ServerAdmin admin@localhost

ServerName localhost:80

DocumentRoot "C:/xampp/htdocs"  

<Directory />
    Options FollowSymLinks
    AllowOverride None
    Order deny,allow
    Deny from all
</Directory>


<Directory "C:/xampp/htdocs">  
    Options Indexes FollowSymLinks Includes ExecCGI
   
    AllowOverride All

    Order allow,deny
    Allow from all

</Directory>

<IfModule dir_module>
    DirectoryIndex index.php index.php4 index.php3 index.cgi index.pl index.html index.htm index.shtml index.phtml
</IfModule>

<FilesMatch "^\.ht">  
    Order allow,deny
    Deny from all
</FilesMatch>

ErrorLog logs/error.log

LogLevel warn

<IfModule log_config_module>
    LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\"" combined  
    LogFormat "%h %l %u %t \"%r\" %>s %b" common  

    <IfModule logio_module>
      LogFormat "%h %l %u %t \"%r\" %>s %b \"%{Referer}i\" \"%{User-Agent}i\" %I %O" combinedio  
    </IfModule>

    CustomLog logs/access.log common

</IfModule>

<IfModule alias_module>


    ScriptAlias /cgi-bin/ "C:/xampp/cgi-bin/"  

</IfModule>

<Directory "C:/xampp/cgi-bin">  
    AllowOverride ALL
    Options ALL
    Options ExecCGI
    Order allow,deny
    Allow from all
    AddHandler cgi-script .exe
</Directory>




DefaultType text/plain

<IfModule mime_module>
    TypesConfig conf/mime.types

    AddType application/x-compress .Z
    AddType application/x-gzip .gz .tgz

    AddHandler cgi-script .cgi .exe




   AddType text/html .shtml
   AddOutputFilter INCLUDES .shtml
</IfModule>



EnableMMAP off
EnableSendfile off


Include conf/extra/httpd-xampp.conf


Include conf/extra/httpd-multilang-errordoc.conf

Include conf/extra/httpd-autoindex.conf

Include conf/extra/httpd-languages.conf

Include conf/extra/httpd-userdir.conf

Include conf/extra/httpd-info.conf

Include conf/extra/httpd-vhosts.conf

Include conf/extra/httpd-manual.conf

Include conf/extra/httpd-dav.conf

Include conf/extra/httpd-default.conf

Include conf/extra/httpd-ssl.conf

<IfModule ssl_module>
SSLRandomSeed startup builtin
SSLRandomSeed connect builtin
</IfModule>
Mitglied: DerBiba
DerBiba 06.09.2007 um 12:51:02 Uhr
Goto Top
Sorry, hab grad etwas Stress und nicht alle Zeit zum durcharbeiten. Hab's also nur überfliegen können. Muss meinen Flieger noch kriegen....

Ergänze mal noch bei dir ein
AddType text/html .exe

AddType application/x-compress .Z
AddType application/x-gzip .gz .tgz

AddHandler cgi-script .cgi .exe

AddType text/html .exe

AddType text/html .shtml
AddOutputFilter INCLUDES .shtml
</IfModule>

Dann den Apache rebooten und probieren.

Wenn nicht gleich geht, mal in der HTML-Seite das "cgiexe" in cgiexe.exe ändern. Wieder testen und wenns immer noch nicht geht, wieder melden.
Bin auch von unterwegs häufiger online und schau wieder rein face-smile

Viel Glück und schönes WE, Biba
Mitglied: danix
danix 06.09.2007 um 13:03:24 Uhr
Goto Top
Danke, scheint besser zu sein... der Download ist nun weg, dafür ein interner Serverfehler:

Serverfehler!

Die Anfrage kann nicht beantwortet werden, da im Server ein interner Fehler aufgetreten ist.

Fehlermeldung:
Premature end of script headers: cgiexe.exe

Sofern Sie dies für eine Fehlfunktion des Servers halten, informieren Sie bitte den Webmaster hierüber.
Error 500
127.0.0.1
09/06/07 13:01:43
Apache/2.2.4 (Win32) DAV/2 mod_ssl/2.2.4 OpenSSL/0.9.8e mod_autoindex_color PHP/5.2.1

Auch dir ein schönes WE!
Gruß
danix
Mitglied: Dani
Dani 03.10.2007 um 01:03:16 Uhr
Goto Top
Hi!
Hast du den Fehler nun beseitigen können? Falls "Ja" möchte ich dich bitten, noch kurz einen Abschlusskommentar + Lösung zu schreiben.


Grüße
Dani
Mitglied: danix
danix 03.10.2007 um 14:44:30 Uhr
Goto Top
nein leider noch nicht. Tut mir Leid, aber wenn es denn so weit ist werde ich das tun.