Author |
Message
|
sjensen |
Posted: Thu May 25, 2006 3:58 am Post subject: Passing arguments to wmbt.exe -Solved |
|
|
Centurion
Joined: 18 Dec 2003 Posts: 134 Location: London
|
Hi,
We have implemented a java security exit on the toolkit on windows. The exit takes a username and password. It would be preferable to supply these on a command line invocation of wmbt.exe. I know it takes a
arguments and looking at the wmbt.ini file there are a number of
statement. I've had no luck trying to pass username/password however. Is there an overview of the arguments wmbt.exe will take and how to pass them?
Toolkit running on Windows 2003 server and XP-Pro
Many Thanks
Stefan
Last edited by sjensen on Fri May 26, 2006 6:28 am; edited 1 time in total |
|
Back to top |
|
 |
jefflowrey |
Posted: Thu May 25, 2006 4:18 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
The only way I know that you could do this would be to use java system properties.
So do "-VMArgs= -Dmy.java.property.username=<username> -Dmy.java.property.password=<password>". And then code your security exit to get the values of my.java.property.username and my.java.property.password.
There is a list of the runtime options for Eclipse in the Help of the broker toolkit. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
sjensen |
Posted: Thu May 25, 2006 7:22 am Post subject: |
|
|
Centurion
Joined: 18 Dec 2003 Posts: 134 Location: London
|
Hi,
Thanks. I tried adding that on the command line. However it did not work .
I tried:
Code: |
wmbt.exe -VMArgs=Djava.property.username=<user> -VMArgs=-Djava.property.password=<passwd> |
and
Code: |
wmbt.exe "-VMArgs=Djava.property.username=<user> -VMArgs=-Djava.property.password=<passwd>" |
and
Code: |
wmbt.exe VMArgs=Djava.property.username=<user> VMArgs=-Djava.property.password=<passwd> |
and
Code: |
wmbt.exe "VMArgs=Djava.property.username=<user> VMArgs=-Djava.property.password=<passwd>" |
None of them worked so is this simply not possible or am I doing something stupid (again )?
Thanks
Stefan |
|
Back to top |
|
 |
jefflowrey |
Posted: Thu May 25, 2006 7:25 am Post subject: |
|
|
Grand Poobah
Joined: 16 Oct 2002 Posts: 19981
|
sjensen wrote: |
None of them worked so is this simply not possible or am I doing something stupid (again )? |
How did it not work? Did the toolkit not launch?
It's entirely possible that my syntax is wrong. It was from the top of my head. So it might be that I did something stupid, not you. _________________ I am *not* the model of the modern major general. |
|
Back to top |
|
 |
sjensen |
Posted: Thu May 25, 2006 8:01 am Post subject: |
|
|
Centurion
Joined: 18 Dec 2003 Posts: 134 Location: London
|
Hi,
Toolkit launches but the arguments are not passed to the exit. The way the exit works if the username/password is not passed it will prompt and alas it prompts. If I put the java property lines into config.ini it works but I do not want passwords in a file really and it is in the product directory so for all users on the machine. The syntax looks like the one used in wmbt.ini I've tried most combinations I think.
Thanks
Stefan |
|
Back to top |
|
 |
sjensen |
Posted: Fri May 26, 2006 6:31 am Post subject: |
|
|
Centurion
Joined: 18 Dec 2003 Posts: 134 Location: London
|
Hi,
Got it. This works:
Code: |
wmbt.exe -vmargs "-Djava.property.username=<user>" "-Djava.property.password=<passwd>" |
 |
|
Back to top |
|
 |
|