Commit 10e0cc48 authored by Guus der Kinderen's avatar Guus der Kinderen

OF-1092: Provider should register all mechanisms.

The provider didn't register all of the supported SASL mechanisms. For good measure,
the version number of the provider was increased as well.
parent d4c2e12b
...@@ -33,11 +33,14 @@ public class SaslProvider extends Provider { ...@@ -33,11 +33,14 @@ public class SaslProvider extends Provider {
/** /**
* Constructs a the JiveSoftware SASL provider. * Constructs a the JiveSoftware SASL provider.
*/ */
public SaslProvider() { public SaslProvider()
super("JiveSoftware", 1.0, "JiveSoftware SASL provider v1.0, implementing server mechanisms for: PLAIN, SCRAM-SHA-1"); {
// Add SaslServer supporting the PLAIN SASL mechanism super("JiveSoftware", 1.1, "JiveSoftware Openfire SASL provider v1.1" );
put("SaslServerFactory.PLAIN", "org.jivesoftware.openfire.sasl.SaslServerFactoryImpl");
// Add SaslServer supporting the SCRAM-SHA-1 SASL mechanism final SaslServerFactoryImpl serverFactory = new SaslServerFactoryImpl();
put("SaslServerFactory.SCRAM-SHA-1", "org.jivesoftware.openfire.sasl.SaslServerFactoryImpl"); for ( final String name : serverFactory.getMechanismNames( null ) )
{
put( "SaslServerFactory." + name, serverFactory.getClass().getCanonicalName() );
}
} }
} }
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment