Warn of ! in password during wizards

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
pentiumone133
Posts: 13
Joined: Tue Mar 29, 2016 2:48 pm

Warn of ! in password during wizards

Post by pentiumone133 »

I've noticed that if you modify an existing service an include a ! in the command, you are warned that ! is a special character.

You don't receive the same warning when you specify a password with ! character when adding a service using the wizards. In my case it was specifically the MSSQL Database wizard.

This one took me awhile to figure out, very new to nagios.
Attachments
chrome_2016-03-29_15-55-45.png
chrome_2016-03-29_15-55-45.png (10.88 KiB) Viewed 3114 times
tmcdonald
Posts: 9117
Joined: Mon Sep 23, 2013 8:40 am

Re: Warn of ! in password during wizards

Post by tmcdonald »

What NagiosXI and wizard versions are you using? XI version is in the lower-left of the interface, and wizard can be found under Admin -> Manage Config Wizards
Former Nagios employee
pentiumone133
Posts: 13
Joined: Tue Mar 29, 2016 2:48 pm

Re: Warn of ! in password during wizards

Post by pentiumone133 »

tmcdonald wrote:What NagiosXI and wizard versions are you using? XI version is in the lower-left of the interface, and wizard can be found under Admin -> Manage Config Wizards

Nagios is 5.2.5, the plugin is "MSSQL Database" Version 1.5.6.
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: Warn of ! in password during wizards

Post by hsmith »

Did the check still function as expected? Would you like to see the warning pop up on passwords as well?
Former Nagios Employee.
me.
pentiumone133
Posts: 13
Joined: Tue Mar 29, 2016 2:48 pm

Re: Warn of ! in password during wizards

Post by pentiumone133 »

hsmith wrote:Did the check still function as expected? Would you like to see the warning pop up on passwords as well?
No the check failed with an authentication error. It makes sense now that I've seen that error message when I started working with the command manually, but it had me stumped since I knew I used the wrong password. Like I said, I'm very new to XI and I'll never make the mistake again, just might be helpful to be warned of inappropriate characters during the wizard.
User avatar
hsmith
Agent Smith
Posts: 3539
Joined: Thu Jul 30, 2015 11:09 am
Location: 127.0.0.1
Contact:

Re: Warn of ! in password during wizards

Post by hsmith »

Can you try to escape out the ! in the password? For instance in your check, have it look something like \!goodpassword instead of !goodpassword. Otherwise, you can save the password in /usr/local/nagios/etc/resource.cfg as something like this:

$USER6$=!goodpassword

and then call $USER6$ for the password instead of the actual password. Does that make sense?
Former Nagios Employee.
me.
Locked