KEYCLOAK-14902 Replace SAML SP metadata export with link to descriptor
This commit is contained in:
parent
b392084297
commit
03c07bd2d7
5 changed files with 9 additions and 48 deletions
|
@ -664,6 +664,8 @@ import-from-url=Import from URL
|
||||||
identity-provider.import-from-url.tooltip=Import metadata from a remote IDP discovery descriptor.
|
identity-provider.import-from-url.tooltip=Import metadata from a remote IDP discovery descriptor.
|
||||||
import-from-file=Import from file
|
import-from-file=Import from file
|
||||||
identity-provider.import-from-file.tooltip=Import metadata from a downloaded IDP discovery descriptor.
|
identity-provider.import-from-file.tooltip=Import metadata from a downloaded IDP discovery descriptor.
|
||||||
|
identity-provider.saml.protocol-endpoints.saml=SAML 2.0 Service Provider Metadata
|
||||||
|
identity-provider.saml.protocol-endpoints.saml.tooltip=Shows the configuration of the Service Provider endpoint
|
||||||
saml-config=SAML Config
|
saml-config=SAML Config
|
||||||
identity-provider.saml-config.tooltip=SAML SP and external IDP configuration.
|
identity-provider.saml-config.tooltip=SAML SP and external IDP configuration.
|
||||||
single-signon-service-url=Single Sign-On Service URL
|
single-signon-service-url=Single Sign-On Service URL
|
||||||
|
|
|
@ -1122,30 +1122,6 @@ module.controller('RealmIdentityProviderCtrl', function($scope, $filter, $upload
|
||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
module.controller('RealmIdentityProviderExportCtrl', function(realm, identityProvider, $scope, $http, IdentityProviderExport) {
|
|
||||||
$scope.realm = realm;
|
|
||||||
$scope.identityProvider = identityProvider;
|
|
||||||
$scope.download = null;
|
|
||||||
$scope.exported = "";
|
|
||||||
$scope.exportedType = "";
|
|
||||||
|
|
||||||
var url = IdentityProviderExport.url({realm: realm.realm, alias: identityProvider.alias}) ;
|
|
||||||
$http.get(url).then(function(response) {
|
|
||||||
$scope.exportedType = response.headers('Content-Type');
|
|
||||||
$scope.exported = response.data;
|
|
||||||
});
|
|
||||||
|
|
||||||
$scope.download = function() {
|
|
||||||
var suffix = "txt";
|
|
||||||
if ($scope.exportedType == 'application/xml') {
|
|
||||||
suffix = 'xml';
|
|
||||||
} else if ($scope.exportedType == 'application/json') {
|
|
||||||
suffix = 'json';
|
|
||||||
}
|
|
||||||
saveAs(new Blob([$scope.exported], { type: $scope.exportedType }), 'keycloak.' + suffix);
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
module.controller('RealmTokenDetailCtrl', function($scope, Realm, realm, $http, $location, $route, Dialog, Notifications, TimeUnit, TimeUnit2, serverInfo) {
|
module.controller('RealmTokenDetailCtrl', function($scope, Realm, realm, $http, $location, $route, Dialog, Notifications, TimeUnit, TimeUnit2, serverInfo) {
|
||||||
$scope.realm = realm;
|
$scope.realm = realm;
|
||||||
$scope.serverInfo = serverInfo;
|
$scope.serverInfo = serverInfo;
|
||||||
|
|
|
@ -1,23 +0,0 @@
|
||||||
<div class="col-sm-9 col-md-10 col-sm-push-3 col-md-push-2" data-ng-init="initProvider()">
|
|
||||||
<ol class="breadcrumb">
|
|
||||||
<li><a href="#/realms/{{realm.realm}}/identity-provider-settings">{{:: 'identity-providers' | translate}}</a></li>
|
|
||||||
<li data-ng-show="identityProvider.displayName"><a href="#/realms/{{realm.realm}}/identity-provider-settings/provider/{{identityProvider.providerId}}/{{identityProvider.alias}}">{{identityProvider.displayName}}</a></li>
|
|
||||||
<li data-ng-show="!identityProvider.displayName"><a href="#/realms/{{realm.realm}}/identity-provider-settings/provider/{{identityProvider.providerId}}/{{identityProvider.alias}}">{{identityProvider.alias}}</a></li>
|
|
||||||
<li>{{:: 'export' | translate}}</li>
|
|
||||||
</ol>
|
|
||||||
|
|
||||||
<kc-tabs-identity-provider></kc-tabs-identity-provider>
|
|
||||||
|
|
||||||
<form class="form-horizontal" name="realmForm" novalidate>
|
|
||||||
<fieldset class="border-top">
|
|
||||||
<div class="form-group">
|
|
||||||
<div class="col-sm-12">
|
|
||||||
<a class="btn btn-primary" data-ng-click="download()" type="submit">{{:: 'download' | translate}}</a>
|
|
||||||
<textarea class="form-control" rows="20" kc-select-action="click">{{exported}}</textarea>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</fieldset>
|
|
||||||
</form>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<kc-menu></kc-menu>
|
|
|
@ -122,6 +122,13 @@
|
||||||
</div>
|
</div>
|
||||||
<kc-tooltip>{{:: 'sync-mode.tooltip' | translate}}</kc-tooltip>
|
<kc-tooltip>{{:: 'sync-mode.tooltip' | translate}}</kc-tooltip>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="form-group" data-ng-show="!importFile && !newIdentityProvider">
|
||||||
|
<label class="col-md-2 control-label">{{:: 'endpoints' | translate}}</label>
|
||||||
|
<div class="col-md-6">
|
||||||
|
<a class="form-control" ng-href="{{callbackUrl}}{{identityProvider.alias}}/endpoint/descriptor" target="_blank">{{:: 'identity-provider.saml.protocol-endpoints.saml' | translate}}</a>
|
||||||
|
</div>
|
||||||
|
<kc-tooltip>{{:: 'identity-provider.saml.protocol-endpoints.saml.tooltip' | translate}}</kc-tooltip>
|
||||||
|
</div>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
<fieldset>
|
<fieldset>
|
||||||
<legend uncollapsed><span class="text">{{:: 'saml-config' | translate}}</span> <kc-tooltip>{{:: 'identity-provider.saml-config.tooltip' | translate}}</kc-tooltip></legend>
|
<legend uncollapsed><span class="text">{{:: 'saml-config' | translate}}</span> <kc-tooltip>{{:: 'identity-provider.saml-config.tooltip' | translate}}</kc-tooltip></legend>
|
||||||
|
|
|
@ -11,7 +11,6 @@
|
||||||
<ul class="nav nav-tabs" data-ng-hide="newIdentityProvider">
|
<ul class="nav nav-tabs" data-ng-hide="newIdentityProvider">
|
||||||
<li ng-class="{active: !path[6] && path.length > 5}"><a href="#/realms/{{realm.realm}}/identity-provider-settings/provider/{{identityProvider.providerId}}/{{identityProvider.alias}}">{{:: 'settings' | translate}}</a></li>
|
<li ng-class="{active: !path[6] && path.length > 5}"><a href="#/realms/{{realm.realm}}/identity-provider-settings/provider/{{identityProvider.providerId}}/{{identityProvider.alias}}">{{:: 'settings' | translate}}</a></li>
|
||||||
<li ng-class="{active: path[4] == 'mappers'}"><a href="#/realms/{{realm.realm}}/identity-provider-mappers/{{identityProvider.alias}}/mappers">{{:: 'mappers' | translate}}</a></li>
|
<li ng-class="{active: path[4] == 'mappers'}"><a href="#/realms/{{realm.realm}}/identity-provider-mappers/{{identityProvider.alias}}/mappers">{{:: 'mappers' | translate}}</a></li>
|
||||||
<li ng-class="{active: path[6] == 'export'}"><a href="#/realms/{{realm.realm}}/identity-provider-settings/provider/{{identityProvider.providerId}}/{{identityProvider.alias}}/export" data-ng-show="!importFile && !newIdentityProvider && identityProvider.providerId == 'saml'">{{:: 'export' | translate}}</a></li>
|
|
||||||
<li ng-class="{active: path[6] == 'permissions'}" data-ng-show="serverInfo.featureEnabled('ADMIN_FINE_GRAINED_AUTHZ') && !newIdentityProvider && access.manageAuthorization"><a href="#/realms/{{realm.realm}}/identity-provider-settings/provider/{{identityProvider.providerId}}/{{identityProvider.alias}}/permissions">{{:: 'authz-permissions' | translate}}</a></li>
|
<li ng-class="{active: path[6] == 'permissions'}" data-ng-show="serverInfo.featureEnabled('ADMIN_FINE_GRAINED_AUTHZ') && !newIdentityProvider && access.manageAuthorization"><a href="#/realms/{{realm.realm}}/identity-provider-settings/provider/{{identityProvider.providerId}}/{{identityProvider.alias}}/permissions">{{:: 'authz-permissions' | translate}}</a></li>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
|
Loading…
Reference in a new issue