Package io.fathom.cloud.identity.api.os.model.v2

Examples of io.fathom.cloud.identity.api.os.model.v2.Tenant


            if (!hasChallengeResponse) {
                if (clientCertificate != null) {
                    // Request for challenge
                    ByteString challenge = loginService.getChallenge(clientCertificate);
                    if (challenge != null) {
                        V2AuthResponse response = new V2AuthResponse();
                        response.challenge = BaseEncoding.base64().encode(challenge.toByteArray());
                        return response;
                    }

                }
            }
        }

        AuthenticatedUser authentication = null;

        if (authRequest != null) {
            authentication = loginService.authenticate(authRequest, clientCertificate);
        }

        if (authentication == null) {
            throw new WebApplicationException(Status.UNAUTHORIZED);
        }

        V2AuthResponse response = new V2AuthResponse();

        Access access = response.access = new Access();
        V2Token token = access.token = new V2Token();

        ProjectData project = authentication.getProject();
View Full Code Here


        Map<String, V2Endpoint> v2Endpoints = Maps.newHashMap();

        for (Endpoint v3 : v3Endpoints) {
            String key = v3.region;

            V2Endpoint v2 = v2Endpoints.get(key);
            if (v2 == null) {
                v2 = new V2Endpoint();
                v2Endpoints.put(key, v2);

                v2.tenantId = "" + project.getId();

                v2.region = v3.region;
View Full Code Here

    }

    private List<V2Service> toV2Services(ProjectData project, List<Service> v3Services) {
        List<V2Service> v2Services = Lists.newArrayList();
        for (Service v3 : v3Services) {
            V2Service v2 = new V2Service();
            v2Services.add(v2);

            v2.name = v3.name;
            v2.type = v3.type;
            v2.endpoints = toV2Endpoints(project, v3.endpoints);
View Full Code Here

        }

        V2AuthResponse response = new V2AuthResponse();

        Access access = response.access = new Access();
        V2Token token = access.token = new V2Token();

        ProjectData project = authentication.getProject();

        // We never pass domain; we can't build a domain token with V2
        TokenInfo tokenInfo = loginService.buildTokenInfo(authentication);
View Full Code Here

TOP

Related Classes of io.fathom.cloud.identity.api.os.model.v2.Tenant

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.