I have not tested XOR without a password, how about try
withPassword("") to see if that works
The encyrpt method has the following snippet
if (StringUtils.isNotBlank(password)) {
final byte[] passwordBytes = password.getBytes();
for (int y = 0, x = 0; y < passiveCheckBytes.length; y++, x++) {
if (x >= passwordBytes.length) {
x = 0;
}
passiveCheckBytes[y] ^= passwordBytes[x];
}
}
So if the password is blank, it will skip over this and may work
Regards
Raj
> --
> You received this message because you are subscribed to the Google Groups "jsend-nsca" group.
> To post to this group, send email to jsend...@googlegroups.com.
> To unsubscribe from this group, send email to jsend-nsca+...@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/jsend-nsca?hl=en.
>
--
Raj Patel
Mobile: 07957 446908
Home: 0208 371 1958
Looks like i need to accept "" as a valid password,
The reason why " " works is the StringUtils.isNotBlank() returns false
for this hence the code is skipped over
As no password seems like the NSCA default, I will fix this so that
withPassword() accepts an empty string and the default password is an
empty string
So the current workaround seems to be a space " " so glad that works for you
Regards
Raj Patel
Issue is now hopefully fixed.
New version 2.0.1 uploaded which has empty string as default password.
You can also optionally now use new withNoPassword method on builder
so it is clear
that you are not setting a password
NagiosSettings settings = new NagiosSettingsBuilder()
...
.withNoPassword()
.create();
Can you give 2.0.1 a try and see if it works for you
Regards
Raj Patel