java-rmi.cgi 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. #!/bin/sh
  2. # ===========================================================================
  3. # Licensed Materials - Property of IBM
  4. # "Restricted Materials of IBM"
  5. #
  6. # IBM SDK, Java(tm) Technology Edition, v8
  7. # (C) Copyright IBM Corp. 1996, 1996. All Rights Reserved
  8. #
  9. # US Government Users Restricted Rights - Use, duplication or disclosure
  10. # restricted by GSA ADP Schedule Contract with IBM Corp.
  11. # ===========================================================================
  12. #
  13. # Copyright (c) 1996, Oracle and/or its affiliates. All rights reserved.
  14. # ORACLE PROPRIETARY/CONFIDENTIAL. Use is subject to license terms.
  15. #
  16. #
  17. #
  18. #
  19. #
  20. #
  21. #
  22. #
  23. #
  24. #
  25. #
  26. #
  27. #
  28. #
  29. #
  30. #
  31. #
  32. #
  33. #
  34. #
  35. #
  36. #
  37. #
  38. #
  39. # This script executes the Java interpreter, defines properties
  40. # that correspond to the CGI 1.0 environment variables, and executes
  41. # the class "sun.rmi.transport.proxy.CGIHandler". It should be
  42. # installed in the directory to which the HTTP server maps the
  43. # URL path "/cgi-bin".
  44. #
  45. # (Configuration is necessary as noted below.)
  46. #
  47. # This class will support a QUERY_STRING of the form "forward=<port>"
  48. # with a REQUEST_METHOD "POST". The body of the request will be
  49. # forwarded (as another POST request) to the server listening on the
  50. # specified port (must be >= 1024). The response from this forwarded
  51. # request will be the response to the original request.
  52. #
  53. # CONFIGURATION:
  54. #
  55. # Fill in correct absolute path to Java interpreter below. For example,
  56. # the "PATH=" line might be changed to the follow if the JDK is installed
  57. # at the path "/home/peter/java":
  58. #
  59. # PATH=/home/peter/java/bin:$PATH
  60. #
  61. PATH=/usr/local/java/bin:$PATH
  62. exec java \
  63. -DAUTH_TYPE="$AUTH_TYPE" \
  64. -DCONTENT_LENGTH="$CONTENT_LENGTH" \
  65. -DCONTENT_TYPE="$CONTENT_TYPE" \
  66. -DGATEWAY_INTERFACE="$GATEWAY_INTERFACE" \
  67. -DHTTP_ACCEPT="$HTTP_ACCEPT" \
  68. -DPATH_INFO="$PATH_INFO" \
  69. -DPATH_TRANSLATED="$PATH_TRANSLATED" \
  70. -DQUERY_STRING="$QUERY_STRING" \
  71. -DREMOTE_ADDR="$REMOTE_ADDR" \
  72. -DREMOTE_HOST="$REMOTE_HOST" \
  73. -DREMOTE_IDENT="$REMOTE_IDENT" \
  74. -DREMOTE_USER="$REMOTE_USER" \
  75. -DREQUEST_METHOD="$REQUEST_METHOD" \
  76. -DSCRIPT_NAME="$SCRIPT_NAME" \
  77. -DSERVER_NAME="$SERVER_NAME" \
  78. -DSERVER_PORT="$SERVER_PORT" \
  79. -DSERVER_PROTOCOL="$SERVER_PROTOCOL" \
  80. -DSERVER_SOFTWARE="$SERVER_SOFTWARE" \
  81. sun.rmi.transport.proxy.CGIHandler