Skip to content

ajpclient is a small command line tool that aims to be to AJP what curl is to HTTP.

Notifications You must be signed in to change notification settings

alexmadon/ajpclient

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ajpclient

When testing an java app running on tomcat on the 8009 ajp13 connector, you can create an apache proxy with mod_proxy and connect to your tomcat using that proxy.

For test and QA purposes, it is sometimes easier to send a curl like command.

This tool aims to be to AJP13 what curl is to HTTP.

To get help, use the -h flag:

./ajprequest.py -h
usage: ajprequest.py [-h] [-H HEADER] [-r REMOTE_USER]
                     [-X {GET,POST,HEAD,OPTIONS,PROPFIND}] [-l {INFO,DEBUG}]
                     [-d DATA]
                     requesturl [passurl]

A python AJP client

positional arguments:
  requesturl            The request to the proxy front end, e.g. https://localh
                        ost/alfresco/faces/jsp/dashboards/container.jsp
  passurl               The proxy pass url (default:
                        ajp:https://localhost:8009/alfresco)

optional arguments:
  -h, --help            show this help message and exit
  -H HEADER, --header HEADER
                        adds a header
  -r REMOTE_USER, --remote_user REMOTE_USER
                        Sets the remote_user CGI variable
  -X {GET,POST,HEAD,OPTIONS,PROPFIND}
                        Sets the method (default: GET).
  -l {INFO,DEBUG}, --log_level {INFO,DEBUG}
                        Sets the log level. Logs are sent to STDERR.
  -d DATA, --data DATA  The data to POST

The AJPv13 protocol is documented at: https://tomcat.apache.org/connectors-doc-
archive/jk2/common/AJPv13.html

This script has been used to log several Alfresco Jiras.

About

ajpclient is a small command line tool that aims to be to AJP what curl is to HTTP.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published