Merge "Correctly report available for ADFS plugin"
This commit is contained in:
commit
5a40432cdb
@ -13,6 +13,7 @@
|
|||||||
from keystoneauth1.extras._saml2 import v3
|
from keystoneauth1.extras._saml2 import v3
|
||||||
|
|
||||||
_V3_SAML2_AVAILABLE = v3._SAML2_AVAILABLE
|
_V3_SAML2_AVAILABLE = v3._SAML2_AVAILABLE
|
||||||
|
_V3_ADFS_AVAILABLE = v3._ADFS_AVAILABLE
|
||||||
|
|
||||||
V3Saml2Password = v3.Saml2Password
|
V3Saml2Password = v3.Saml2Password
|
||||||
V3ADFSPassword = v3.ADFSPassword
|
V3ADFSPassword = v3.ADFSPassword
|
||||||
|
@ -44,6 +44,10 @@ class ADFSPassword(loading.BaseFederationLoader):
|
|||||||
def plugin_class(self):
|
def plugin_class(self):
|
||||||
return _saml2.V3ADFSPassword
|
return _saml2.V3ADFSPassword
|
||||||
|
|
||||||
|
@property
|
||||||
|
def available(self):
|
||||||
|
return _saml2._V3_ADFS_AVAILABLE
|
||||||
|
|
||||||
def get_options(self):
|
def get_options(self):
|
||||||
options = super(ADFSPassword, self).get_options()
|
options = super(ADFSPassword, self).get_options()
|
||||||
|
|
||||||
|
@ -11,9 +11,11 @@
|
|||||||
# under the License.
|
# under the License.
|
||||||
|
|
||||||
from keystoneauth1.extras._saml2.v3 import adfs
|
from keystoneauth1.extras._saml2.v3 import adfs
|
||||||
|
from keystoneauth1.extras._saml2.v3 import base
|
||||||
from keystoneauth1.extras._saml2.v3 import saml2
|
from keystoneauth1.extras._saml2.v3 import saml2
|
||||||
|
|
||||||
_SAML2_AVAILABLE = saml2.etree is not None
|
_SAML2_AVAILABLE = base.etree is not None and saml2.etree is not None
|
||||||
|
_ADFS_AVAILABLE = base.etree is not None and adfs.etree is not None
|
||||||
|
|
||||||
Saml2Password = saml2.Password
|
Saml2Password = saml2.Password
|
||||||
ADFSPassword = adfs.Password
|
ADFSPassword = adfs.Password
|
||||||
|
@ -13,7 +13,11 @@
|
|||||||
import datetime
|
import datetime
|
||||||
import uuid
|
import uuid
|
||||||
|
|
||||||
from lxml import etree
|
try:
|
||||||
|
from lxml import etree
|
||||||
|
except ImportError:
|
||||||
|
etree = None
|
||||||
|
|
||||||
from six.moves import urllib
|
from six.moves import urllib
|
||||||
|
|
||||||
from keystoneauth1 import access
|
from keystoneauth1 import access
|
||||||
|
@ -10,7 +10,10 @@
|
|||||||
# License for the specific language governing permissions and limitations
|
# License for the specific language governing permissions and limitations
|
||||||
# under the License.
|
# under the License.
|
||||||
|
|
||||||
from lxml import etree
|
try:
|
||||||
|
from lxml import etree
|
||||||
|
except ImportError:
|
||||||
|
etree = None
|
||||||
|
|
||||||
from keystoneauth1 import exceptions
|
from keystoneauth1 import exceptions
|
||||||
from keystoneauth1.identity import v3
|
from keystoneauth1.identity import v3
|
||||||
|
Loading…
Reference in New Issue
Block a user