RMS SDK for C++  0.2.1
A client library for using Microsoft RMS from Linux.
AuthenticatorTemplate.h
1 /*
2  * ======================================================================
3  * Copyright (c) Microsoft Open Technologies, Inc. All rights reserved.
4  * Licensed under the MIT License.
5  * See LICENSE.md in the project root for license information.
6  * ======================================================================
7 */
8 
9 #ifndef AUTHENTICATORTEMPLATE_H
10 #define AUTHENTICATORTEMPLATE_H
11 #include <string>
12 #include "CallState.h"
13 #include "types.h"
14 
15 namespace rmsauth {
16 
18 {
19  static const String& Tag() {static const String tag="AuthenticatorTemplate"; return tag;}
20 
21  String host_;
22  String issuer_;
23  String authority_;
24  String instanceDiscoveryEndpoint_;
25  String authorizeEndpoint_;
26  String tokenEndpoint_;
27  String userRealmEndpoint_;
28 
29  static const String authorizeEndpointTemplate();
30  static const String HOST();
31  static const String TENANT();
32 
33 public:
34  const String& host() const {return host_;}
35  const String& issuer() const {return issuer_;}
36  const String& authority() const {return authority_;}
37  const String& instanceDiscoveryEndpoint() const {return instanceDiscoveryEndpoint_;}
38  const String& authorizeEndpoint() const {return authorizeEndpoint_;}
39  const String& tokenEndpoint() const {return tokenEndpoint_;}
40  const String& userRealmEndpoint() const {return userRealmEndpoint_;}
41 
42  static ptr<AuthenticatorTemplate> createFromHost(const String& host);
43  void verifyAnotherHostByInstanceDiscoveryAsync(const String& host, const String& tenant, CallStatePtr callState);
44 
45 };
46 
47 using AuthenticatorTemplatePtr = ptr<AuthenticatorTemplate>;
48 
49 } // namespace rmsauth {
50 
51 #endif // AUTHENTICATORTEMPLATE_H
Definition: AuthenticatorTemplate.h:17
Definition: AcquireTokenForClientHandler.h:14