This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<system.identityModel> | |
<identityConfiguration> | |
<securityTokenHandlers> | |
<add type="System.IdentityModel.Tokens.JwtSecurityTokenHandler, System.IdentityModel.Tokens.Jwt" /> | |
</securityTokenHandlers> | |
</identityConfiguration> | |
<system.identityModel> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class MySecurityTokenServiceConfiguration : SecurityTokenServiceConfiguration | |
{ | |
public MySecurityTokenServiceConfiguration() | |
{ | |
ImportSecurityTokenHandlers(); | |
} | |
private void ImportSecurityTokenHandlers() | |
{ | |
SecurityTokenHandlers.AddOrReplace(new JwtSecurityTokenHandler()); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
protected override Scope GetScope(ClaimsPrincipal principal, RequestSecurityToken request) | |
{ | |
bool appRequiresJwt = true; | |
if (appRequiresJwt) | |
{ | |
request.TokenType = "urn:ietf:params:oauth:token-type:jwt"; | |
} | |
return WhateverYouDoToGenerateScope(principal, request); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
var resp = channel.Issue(new RequestSecurityToken() | |
{ | |
RequestType = RequestTypes.Issue, | |
TokenType = "urn:ietf:params:oauth:token-type:jwt", | |
AppliesTo = new EndpointReference("http://azureservices/AdminSite") | |
}, out rstr); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Set-MgmtSvcRelyingPartySettings -Target Admin -MetadataEndpoint | |
"https://sts.syfuhs.net/federationmetadata/2007-06/federationmetadata.xml" -Server localhost\sqlexpress |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"Realm":"http://azureservices/WindowsAuthSite", | |
"Endpoint":"https://adminauth-cloud.syfuhs.net/wsfederation/issue", | |
"Certificates":[ | |
"MIIC6...KnOXw==" | |
] | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
unprotect-MgmtSvcConfiguration -Namespace TenantSite |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
{ | |
"data":{ | |
"id":"1100007A", | |
"type":"1", | |
"detector":"SBM20", | |
"cpm":22, | |
"temperature":23.31, | |
"uptime":107522 | |
} | |
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using CertLib; | |
using System; | |
using System.Security.Cryptography; | |
using System.Security.Cryptography.X509Certificates; | |
namespace KeyGenSigning | |
{ | |
class Program | |
{ | |
static void Main(string[] args) |
OlderNewer