|
RSS Feed - WebSphere MQ Support
|
RSS Feed - Message Broker Support
|
 |
|
Change userid and password |
« View previous topic :: View next topic » |
Author |
Message
|
longtail |
Posted: Sat Jun 28, 2008 9:54 pm Post subject: Change userid and password |
|
|
Novice
Joined: 27 Jan 2008 Posts: 15
|
I want to WMBT ( in developping enviroment on windows) connecting to the BROKER ( and QM) in linux, I have the userid and password of wbiadmin. The problem is on windows I don't want to run another instance of WMBT as wbiadmin ,it's too troublesome.The best choice is the connect to broker with a exit to change the userid and password. And I gooled some articles,found from " http://www.tek-tips.com/viewthread.cfm?qid=895514&page=7 ", but I translate the code to Java so the wmbt could use it, but seems not to work at all, wmbt says :user *** not authorized to access the QM.
case MQXR_INIT_SEC:
*pDataLength = 9;
pChannelExitParms->ExitResponse = MQXCC_SEND_SEC_MSG;
strncpy((char *)AgentBuffer, "WHOAREYOU\0", 10);
fprintf(fp,"Scy exit called for INIT_SEC, resp=%d, buff=%s\n", pChannelExitParms->ExitResponse, (char *)AgentBuffer);
break;
case MQXR_SEC_MSG:
fprintf(fp,"Scy exit called for SEC_MSG, resp=%d, buff=%.10s\n", pChannelExitParms->ExitResponse, (char *)AgentBuffer);
*pDataLength = 20;
pChannelExitParms->ExitResponse = MQXCC_SEND_SEC_MSG;
/******CHANGE userid/password in the following line:********/
strncpy((char *)AgentBuffer, "A000MATA6P207712100\0", 21);
//strncpy((char *)AgentBuffer, "A000MATA6P 207712100\0", 21);
//strncpy((char *)AgentBuffer, "A000Userid Password\0", 21);
/******END OF CHANGE userid/password: **********************/
fprintf(fp,"Scy exit called for SEC_MSG, resp=%d, buff=%.10s\n", pChannelExitParms->ExitResponse, (char *)AgentBuffer);
break;
i know it's only 2-3 lines code, but don't know how the write it , Could any give me a hint? Thanks very much! |
|
Back to top |
|
 |
RogerLacroix |
Posted: Mon Jun 30, 2008 11:20 am Post subject: |
|
|
 Jedi Knight
Joined: 15 May 2001 Posts: 3264 Location: London, ON Canada
|
|
Back to top |
|
 |
|
|
 |
|
Page 1 of 1 |
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|
|