diff --git a/Yavsc/Resources/Yavsc.Resources.YavscLoc.en.resx b/Yavsc/Resources/Yavsc.Resources.YavscLocalisation.en.resx
similarity index 100%
rename from Yavsc/Resources/Yavsc.Resources.YavscLoc.en.resx
rename to Yavsc/Resources/Yavsc.Resources.YavscLocalisation.en.resx
diff --git a/Yavsc/Resources/Yavsc.Resources.YavscLoc.fr.resx b/Yavsc/Resources/Yavsc.Resources.YavscLocalisation.fr.resx
similarity index 99%
rename from Yavsc/Resources/Yavsc.Resources.YavscLoc.fr.resx
rename to Yavsc/Resources/Yavsc.Resources.YavscLocalisation.fr.resx
index b423ce55..5e608438 100644
--- a/Yavsc/Resources/Yavsc.Resources.YavscLoc.fr.resx
+++ b/Yavsc/Resources/Yavsc.Resources.YavscLocalisation.fr.resx
@@ -117,7 +117,7 @@
System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089
- À propos de
+ À propos de
À propos de BookAStar
Bienvenue chez vos stars.
Accès refusé
diff --git a/Yavsc/Views/Application/Details.cshtml b/Yavsc/Views/Application/Details.cshtml
index 13124a7d..905a2416 100644
--- a/Yavsc/Views/Application/Details.cshtml
+++ b/Yavsc/Views/Application/Details.cshtml
@@ -28,6 +28,12 @@
@Html.DisplayFor(model => model.RedirectUri)
+
+ @Html.DisplayNameFor(model => model.ApplicationID)
+
+
+ @Html.DisplayFor(model => model.ApplicationID)
+
@Html.DisplayNameFor(model => model.Secret)
diff --git a/Yavsc/appsettings.json b/Yavsc/appsettings.json
index 2472eead..0879d7c2 100755
--- a/Yavsc/appsettings.json
+++ b/Yavsc/appsettings.json
@@ -14,17 +14,24 @@
},
"Site": {
"Title": "Yavsc",
+ "Slogan":"Yavsc!",
+ "Authority": "http://127.0.0.1:5000/",
+ "Audience": "http://127.0.0.1:5000/",
"Owner": {
- "Name": "Paul",
- "Address": "paul@pschneider.fr"
+ "Name": "[query]",
+ "Address": "bigchief@company.com"
},
"Admin": {
- "Name": "Paul",
- "Address": "contact@pschneider.fr"
+ "Name": "[answer]",
+ "Address": "contact@company.com"
},
"UserFiles": {
"RootDir": "UserFiles",
"Quota": "200M"
+ },
+ "DirNames": {
+ "Bills":"Bills",
+ "Blog":"Blog"
}
},
"Smtp": {
diff --git a/Yavsc/project.lock.json b/Yavsc/project.lock.json
index 7bef13ab..a0cf8cd7 100644
--- a/Yavsc/project.lock.json
+++ b/Yavsc/project.lock.json
@@ -9063,7 +9063,7 @@
},
"MailKit/1.3.0-beta7": {
"type": "package",
- "sha512": "xO66P+XLWyo3/POInJpkCsA0bFI3XmDxsdR+rSXCm9d7kbPU6kFBgvXT4AxW0TaWYUcsaxJEcZdhMgOODWu/ew==",
+ "sha512": "LalD+6uE97WdfZ9Ohmz2ZeYbPXzql4VNazGO/e9PLMENKNPwENc4eSr8v/r+mHY3EsRsAH34DCkub8rA4Zwyrw==",
"files": [
"lib/dotnet5.5/MailKit.dll",
"lib/dotnet5.5/MailKit.xml",
@@ -9088,7 +9088,7 @@
},
"MarkdownDeep.NET/1.5.0": {
"type": "package",
- "sha512": "Y0vPM1u1nNtNhTVI6lZPr80W3PlTJZROmc7oqvjg85XVzVjlZX1Cp5+yOuz+qHa264JosYjzGAiBUQuWdnBeZg==",
+ "sha512": "8UPmeM6TB0ut7EKBd+uA7bY988SN+C9NxKiNqLrlUZrGZQQGiQzomeIm33uyvLJ1Umm23mdf7/fe204AOhYMMw==",
"files": [
"lib/net451/MarkdownDeep.dll",
"MarkdownDeep.NET.1.5.0.nupkg",
@@ -10985,7 +10985,7 @@
},
"MimeKit/1.3.0-beta7": {
"type": "package",
- "sha512": "vWNZ2pDJXTFRHiErdZW6bOPej+sikIOjf8LlZSSiZXgYE2s4raQeHVQtvyGVpoQvx/PKXKoACzJDCkm9hr/OQQ==",
+ "sha512": "M7F4OnPXfcI4AljQUdvok29vz3DEruiqIBDIn6zGVdFQpNpaVbmrp80YLX9SH2hJO+8fSOX6/k3ScUXqZheFSQ==",
"files": [
"lib/dotnet5.4/MimeKit.dll",
"lib/dotnet5.4/MimeKit.xml",
diff --git a/Yavsc/src/Model/Auth/Application.cs b/Yavsc/src/Model/Auth/Application.cs
index ae77e86e..6a4fb345 100644
--- a/Yavsc/src/Model/Auth/Application.cs
+++ b/Yavsc/src/Model/Auth/Application.cs
@@ -1,5 +1,4 @@
using System.ComponentModel.DataAnnotations;
-using System.ComponentModel.DataAnnotations.Schema;
namespace Yavsc
{
diff --git a/Yavsc/src/Startup.cs b/Yavsc/src/Startup.cs
index a3cb2043..cd06311a 100755
--- a/Yavsc/src/Startup.cs
+++ b/Yavsc/src/Startup.cs
@@ -111,6 +111,10 @@ namespace Yavsc
services.Configure(googleSettings);
var cinfoSettings = Configuration.GetSection("Authentication").GetSection("Societeinfo");
services.Configure(cinfoSettings);
+ var oauthLocalAppSettings = Configuration.GetSection("Authentication").GetSection("OAuth2LocalApp");
+ services.Configure(oauthLocalAppSettings);
+ var oauthFacebookSettings = Configuration.GetSection("Authentication").GetSection("Facebook");
+ services.Configure(oauthFacebookSettings);
services.Configure(options =>
{
@@ -171,6 +175,7 @@ namespace Yavsc
services.Add(ServiceDescriptor.Singleton(typeof(IOptions), typeof(OptionsManager)));
services.Add(ServiceDescriptor.Singleton(typeof(IOptions), typeof(OptionsManager)));
services.Add(ServiceDescriptor.Singleton(typeof(IOptions), typeof(OptionsManager)));
+ services.Add(ServiceDescriptor.Singleton(typeof(IOptions), typeof(OptionsManager)));
services.AddTransient();
services.AddDataProtection();
@@ -229,6 +234,10 @@ namespace Yavsc
{
options.AddPolicy("AdministratorOnly", policy => policy.RequireRole(Constants.AdminGroupName));
options.AddPolicy("FrontOffice", policy => policy.RequireRole(Constants.FrontOfficeGroupName));
+ options.AddPolicy("API", policy => {
+ policy.AddAuthenticationSchemes(JwtBearerDefaults.AuthenticationScheme);
+ policy.RequireClaim(OpenIdConnectConstants.Claims.Scope, "api-resource-controller");
+ });
// options.AddPolicy("EmployeeId", policy => policy.RequireClaim("EmployeeId", "123", "456"));
// options.AddPolicy("BuildingEntry", policy => policy.Requirements.Add(new OfficeEntryRequirement()));
});
@@ -259,7 +268,7 @@ namespace Yavsc
{
options.ResourcesPath = "Resources";
})
- .AddDataAnnotationsLocalization();
+ .AddDataAnnotationsLocalization( opt => opt.ResourcesPath = "Resources");
services.AddScoped();
// Inject ticket formatting
@@ -284,6 +293,7 @@ namespace Yavsc
// This method gets called by the runtime. Use this method to configure the HTTP request pipeline.
public void Configure(IApplicationBuilder app, IHostingEnvironment env,
IOptions siteSettings, IOptions localizationOptions,
+ IOptions oauth2SettingsContainer,
ILoggerFactory loggerFactory)
{
loggerFactory.AddConsole(Configuration.GetSection("Logging"));
@@ -326,7 +336,9 @@ namespace Yavsc
{
if (ex.InnerException is InvalidOperationException)
// nothing to do ?
- { }
+ {
+// TODO Send an email to the Admin
+ }
else throw ex;
}
}