Hi Mark,


Thank you for replying on this.



Please find below servlet configuration



<servlet>

        <servlet-name>cgi</servlet-name>

        <servlet-class>org.apache.catalina.servlets.CGIServlet</servlet-class>

        <init-param>

          <param-name>cgiPathPrefix</param-name>

          <param-value>cgi-bin</param-value>

          <param-name>executable</param-name>

          <param-value>/usr/bin/perl</param-value>

        </init-param>

        <load-on-startup>5</load-on-startup>

    </servlet>



<servlet-mapping>

        <servlet-name>cgi</servlet-name>

        <url-pattern>/cgi-bin/*</url-pattern>

    </servlet-mapping>





The url we access is



http://maskedforsecurity:port/maskedapp/cgi-bin/register.cgi?-p





Please note that the cgi files are all under maskedapp/cgi-bin of webapps 
folder.



Also I have observed that even if I don’t configure cgi servlet in web.xml, the 
server is executing the cgi file but it is not able to execute getops method.



Thanks

Swathi



-----Original Message-----
From: Mark Thomas [mailto:ma...@apache.org]
Sent: Friday, November 13, 2020 6:51 PM
To: users@tomcat.apache.org
Subject: Re: getopts of Perl is not working Tomcat 9



CAUTION:   This email originated from outside the organization. Do not click 
links or open attachments unless you recognize the sender and know the content 
is safe.



On 13/11/2020 13:14, Jonnalagadda, Swathi (External) wrote:

> Hi

>

> We have our web application implemented in Perl cgi which is using below 
> function of perl. we are upgrading from Tomcat 8.0.21 to Tomcat 9.0.38.

>

> The below function (getopts) is working fine Tomcat 8.0.21 but is not working 
> in Tomcat 9.0.38. We even tried Tomcat 9.0.39 as well and it is not working 
> even in 9.0.39.

>

> use Getopt::Std;

>

> getopts('ei:npXP');

>

> Could you please suggest a solution here.



How is the CGI servlet configured?



What URL are you using to call the CGI servlet?



Mark



---------------------------------------------------------------------

To unsubscribe, e-mail: 
users-unsubscr...@tomcat.apache.org<mailto:users-unsubscr...@tomcat.apache.org>

For additional commands, e-mail: 
users-h...@tomcat.apache.org<mailto:users-h...@tomcat.apache.org>


Reply via email to