Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

httpd.xml

Code Block
languagejavaactionscript3
<?xml versionxml version="1.0" encoding encoding="UTF-8"?>
 
<configuration>
 
  <instance name  <instance name="WebServer" active active="true" root root="www/instance/htdocs" index index="index.html">
 
 
    <listen port
 
    <listen port="4563" interface interface="*ALL" backlog backlog="256"
            secure            secure="false" store store="pki/wwwssl.jks" password password="password"
            buffersend            buffersend="-1" bufferreceive bufferreceive="-1" nodelay nodelay="false" timeout timeout="5"/>
 
    <access>    <access>

      < 
      <!--
            Once a           Once a true true condition occurs no more evaluations are done.
 
            <deny             <deny address="*"/>
            <deny            <deny address="10.2.1.45"/>
 
            <allow  
            <allow address="*"/>
            <allow             <allow address="10.2.1.45"/>
            -->
 
    <    </access>
 
    <mimetype>    <mimetype>

      < 
      <!--
            These            These are are the default values.
                -->

      <map extension 
      <map extension="png"  type  type="image/png"/>
      <map extension      <map extension="gif"  type  type="image/gif"/>
      <map extension      <map extension="jpg"  type  type="image/jpeg"/>
      <map extension      <map extension="jpeg" type type="image/jpeg"/>
      <map extension      <map extension="tiff" type type="image/tiff"/>
      <map extension      <map extension="ico"  type  type="image/x-icon"/>
      <map extension      <map extension="svg"  type  type="image/svg+xml"/>
      <map extension      <map extension="pdf"  type  type="application/pdf"/>
      <map extension      <map extension="css"  type  type="text/css; charset=utf-8"/>
      <map extension      <map extension="xsl"  type  type="text/xls; charset=utf-8"/>
      <map extension      <map extension="xml"  type  type="text/xml; charset=utf-8"/>
      <map extension      <map extension="htm"  type  type="text/html; charset=utf-8"/>
      <map extension      <map extension="html" type type="text/html; charset=utf-8"/>
      <map extension="js"   type      <map extension="js"   type="application/x-javascript; charset=utf-8"/>
 
    <    </mimetype>

    <virtual host 
    <virtual host="*" active active="true">

      <access>

        < 
      <access>
 
        <!--
              Once               Once a true condition occurs no more evaluations are done.
 
              <deny               <deny address="*"/>
              <deny               <deny address="10.2.1"/>
              <deny address=              <deny address="10.2.1.45"/>
 
              <allow               <allow address="*"/>
              <allow               <allow address="10.2.1"/>
              <allow               <allow address="10.2.1.45"/>
 
              <deny               <deny useragent="*"/>
              <deny               <deny useragent="?"/>
              <deny useragent="edge"              <deny useragent="edge"/>
              <deny               <deny useragent="opera"/>
              <deny               <deny useragent="chrome"/>
              <deny              <deny useragent="safari"/>
              <deny               <deny useragent="android"/>
              <deny              <deny useragent="firefox"/>
              <deny              <deny useragent="explorer"/>
              <deny useragent="explorerimac"/>
              <deny               <deny useragent="imacipad"/>
              <deny               <deny useragent="ipadipod"/>
              <deny               <deny useragent="ipodiphone"/>
              <deny               <deny useragent="iphoneiwork"/>
              <deny               <deny useragent="iworkmsnbot"/>
              <deny               <deny useragent="msnbot"/>
              <deny useragent="lansaua"/>
              <deny              <deny useragent="yahoobot"/>
              <deny               <deny useragent="googlebot"/>
              <deny               <deny useragent="longreach"/>

              <allow  
              <allow useragent="*"/>
              <allow               <allow useragent="?"/>
              <allow               <allow useragent="edge"/>
              <allow               <allow useragent="opera"/>
              <allow              <allow useragent="chrome"/>
              <allow               <allow useragent="safari"/>
              <allow               <allow useragent="android"/>
              <allow              <allow useragent="firefox"/>
              <allow useragent="useragent="firefox"/>
              <allow useragent="explorer"/>
              <allow              <allow useragent="imac"/>
              <allow               <allow useragent="ipad"/>
              <allow               <allow useragent="ipod"/>
              <allow               <allow useragent="iphone"/>
              <allow useragent              <allow useragent="iwork"/>
              <allow               <allow useragent="msnbot"/>
              <allow               <allow useragent="lansaua"/>
              <allow              <allow useragent="yahoobot"/>
              <allow               <allow useragent="googlebot"/>
              <allow               <allow useragent="longreach"/>
 
              <deny              <deny contentlength="4096"/>     Deny access if content length is greater than value
              <allow contentlength="4096"/>    Allow access if content length less than or equal to value

              Zero content length from the browser is a special case and access is allowed for no content connections
        -->
        <!--
              The default is to allow access for all addresses, useragents and content lengths
       -->

      </access>

 
        <match uri="/ping.jsp" class="com.lansa.jsm.JSMHTTPServicePing" trace="false"/>

        <match uri="/" class="com.lansa.jsm.JSMHTTPServiceFile" trace="false">
           <parameter name="cache.maxage"       value="28800"/>
           <parameter name="cache.maxage.pdf"   value="28800"/>
           <parameter name="cache.maxage.image" value="28800"/>
        </match>

 
      <mimetype>

        <map extension="pdf" typecontentlength="4096"/>     Deny access if content length is greater than value
              <allow contentlength="4096"/>    Allow access if content length less than or equal to value
 
              Zero content length from the browser is a special case and access is allowed for no content connections
        -->
        <!--
              The default is to allow access for all addresses, useragents and content lengths
       -->
 
      </access>
 

 
      <mimetype>
 
        <map extension="pdf" type="application/pdf"/>

        < 
        <!--
              Defaults               Defaults to instance mimetype
                    -->

      < 
      </mimetype>
 
    <    </virtual>
 
  <  </instance>
 
</configuration> 

 

カスタムの Java クラスを書いて、HTTP サーバーからの HTTP 要求を処理するには、Java クラスで com.lansa.jsm.JSMHTTPService のインターフェースが実装されていなければなりません。

...