Compare commits

..

9 Commits

Author SHA1 Message Date
Tommy Parnell
39ed336c4d bump version 2018-11-04 09:09:28 -05:00
Tommy Parnell
6850514ca4 Merge pull request #238 from sprice88/master
Adding Configurable Display type to Salesforce Auth Request
2018-11-04 09:06:19 -05:00
Tommy Parnell
17ae5efa21 Merge pull request #248 from woutervs/master
Discord authenticated context mapping
2018-11-04 09:05:05 -05:00
Wouter Van Speybroeck
b86f2b65d3 Fix verified mapping onto context ignoring case for boolean 2018-10-15 14:58:06 +02:00
Wouter Van Speybroeck
c6586f2809 Merge pull request #1 from TerribleDev/master
Merge base into fork
2018-10-15 14:53:32 +02:00
Tommy Parnell
bc06288ea2 Merge pull request #246 from odahcam/patch-1
Fix main heading markup
2018-08-13 05:55:51 -04:00
Luiz Machado
02fa70bbe3 fix main heading 2018-08-08 16:09:44 -03:00
sprice88
b64e7e5d3a Merge pull request #1 from sprice88/configurable_DisplayMode
Added Display mode to SalesforceAuthenticationOptions
2018-05-08 22:30:18 +01:00
Steve Price
b34579f54c Added Display mode to SalesforceAuthenticationOptions 2018-05-08 22:28:23 +01:00
5 changed files with 23 additions and 4 deletions

View File

@@ -1,6 +1,6 @@
[![Build status](https://ci.appveyor.com/api/projects/status/gjlkpp86t8dw164f?svg=true)](https://ci.appveyor.com/project/tparnell8/owinoauthproviders)
#OWIN OAuth Providers
# OWIN OAuth Providers
Provides a set of extra authentication providers for OWIN ([Project Katana](http://katanaproject.codeplex.com/)). This project includes providers for:
- OAuth

View File

@@ -15,7 +15,7 @@ PACKAGES = File.expand_path("packages")
TOOLS = File.expand_path("tools")
NUGET = File.expand_path("#{TOOLS}/nuget")
NUGET_EXE = File.expand_path("#{TOOLS}/nuget/nuget.exe")
@version = "2.24.0"
@version = "2.25.0"
PROJECTS = Dir.glob('src/*').select{|dir| File.directory? dir }
desc 'Retrieve things'

View File

@@ -39,7 +39,7 @@ namespace Owin.Security.Providers.Discord.Provider
Discriminator = TryGetValue(user, "discriminator");
Avatar = TryGetValue(user, "avatar");
Email = TryGetValue(user, "email");
Verified = TryGetValue(user, "verified") == "true";
Verified = TryGetValue(user, "verified").ToLowerInvariant() == "true";
}
public string RefreshToken { get; set; }

View File

@@ -195,7 +195,7 @@ namespace Owin.Security.Providers.Salesforce
var authorizationEndpoint = ComposeAuthorizationEndpoint(properties);
authorizationEndpoint =
$"{authorizationEndpoint}?response_type={"code"}&client_id={Options.ClientId}&redirect_uri={HttpUtility.UrlEncode(redirectUri)}&display={"page"}&immediate={false}&state={Uri.EscapeDataString(state)}";
$"{authorizationEndpoint}?response_type={"code"}&client_id={Options.ClientId}&redirect_uri={HttpUtility.UrlEncode(redirectUri)}&display={Options.DisplayMode}&immediate={false}&state={Uri.EscapeDataString(state)}";
if (Options.Scope != null && Options.Scope.Count > 0)
{

View File

@@ -26,6 +26,21 @@ namespace Owin.Security.Providers.Salesforce
public string Environment { get; set; }
}
/// <summary>
/// Options for Display Mode
/// Changes the login and authorization pages display type. Salesforce supports these values.
/// page—Full-page authorization screen(default)
/// popup—Compact dialog optimized for modern web browser popup windows
/// touch—Mobile-optimized dialog designed for modern smartphones, such as Android and iPhone
/// mobile—Mobile-optimized dialog designed for less capable smartphones, such as BlackBerry OS 5
/// </summary>
public enum Display{
page,
popup,
touch,
mobile
}
/// <summary>
/// Gets or sets the a pinned certificate validator to use to validate the endpoints used
/// in back channel communications belong to Salesforce.
@@ -110,6 +125,10 @@ namespace Owin.Security.Providers.Salesforce
/// <see cref="System.Security.Claims.ClaimsIdentity" />.
/// </summary>
public string SignInAsAuthenticationType { get; set; }
/// <summary>
/// Gets or sets the display—(Optional)
/// </summary>
public Display DisplayMode { get; set; }
/// <summary>
/// Gets or sets the type used to secure data handled by the middleware.