+

Search Tips | Advanced Search

Use the sample protocol bridge credential user exit

Managed File Transfer provides a sample user exit that performs user credential mapping.


About this task

A sample protocol bridge credential exit is provided in the MQ_INSTALLATION_PATH/mqft/samples/protocolBridge directory and in the topic Sample protocol bridge credential user exit. This sample is based on the com.ibm.wmqfte.exitroutine.api.ProtocolBridgeCredentialExit interface.

The SampleCredentialExit.java exit reads a properties file that maps the MQMD user IDs associated with transfer requests to server user IDs and server passwords. The location of the properties file is taken from the protocol bridge agent property protocolBridgeCredentialConfiguration.

To run the sample user exit, complete the following steps:


Procedure

  1. Compile the SampleCredentialExit.java file.
  2. Create a JAR file that contains the compiled exit and its package structure.
  3. Place the JAR file in the MQ_DATA_PATH/mqft/config/coordination_queue_manager/agents/bridge_agent_name/exits directory.
  4. Edit the MQ_DATA_PATH/mqft/config/coordination_queue_manager/agents/bridge_agent_name/agent.properties file to contain the line:
    protocolBridgeCredentialExitClasses=SampleCredentialExit
  5. Edit the property file of the protocol bridge agent to include:
    exitClassPath=IBM MQ installation_directory\mqft\config\configuration_queue_manager\agents\protocol_bridge_agent_name\exits\SampleCredentialExit.jar

    The agent.properties file for an agent is in your MQ_DATA_PATH/mqft/config/coordination_qmgr_name/agents/agent_name directory.

    If we change the agent.properties file, we must restart the agent to pick up the changes.

  6. Create a credential properties file (credentials.properties) in the directory MQ_DATA_PATH/mqft/config/coordination_queue_manager/agents/bridge_agent and edit it to include entries in the format:
    mqUserId=serverUserId,serverPassword
    
  7. Edit the MQ_DATA_PATH/mqft/config/coordination_queue_manager/agents/bridge_agent_name/agent.properties file to contain the line:
    protocolBridgeCredentialConfiguration=MQ_DATA_PATH/mqft/
    config/coordination_queue_manager/agents/bridge_agent_name/credentials.properties
    You must use the absolute path to the credentials.properties file.
  8. Start the protocol bridge agent by using the fteStartAgent command.

Parent topic: Mapping credentials for a file server by using exit classes


Related concepts


Related information

Last updated: 2020-10-04