Skip to content

Commit 9e950ec

Browse files
committed
Upgrade to v4.0.46
1 parent 4558473 commit 9e950ec

31 files changed

+1359
-12361
lines changed

README.md

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,8 @@ Plugins.Add(new AuthFeature(() => new UserSession(),
133133
new LinkedInOAuth2Provider(appSettings),
134134
}) {
135135
HtmlRedirect = "~/",
136-
IncludeRegistrationService = true
136+
IncludeRegistrationService = true,
137+
MaxLoginAttempts = appSettings.Get("MaxLoginAttempts", 5),
137138
});
138139
```
139140

@@ -143,6 +144,7 @@ The above configuration tells the Authentication feature to:
143144
- Allow authentication via Username / Password as well as Twitter, Facebook, Google and LinkedIn OAuth providers
144145
- Redirect unauthenticated users to the home page when authentication is required
145146
- Enable Registration services so new users can be registered at `/register` (then can later Sign-in with Username/Password)
147+
- Set a default **MaxLoginAttempts** of **5** (overridable in AppSettings)
146148

147149
### UserSessions and UserAuth Repositories
148150

@@ -155,15 +157,14 @@ As we're already using an RDBMS the obvious choice is to use an `OrmLiteAuthRepo
155157

156158
```csharp
157159
container.Register<IUserAuthRepository>(c =>
158-
new OrmLiteAuthRepository(c.Resolve<IDbConnectionFactory>()) {
159-
MaxLoginAttempts = appSettings.Get("MaxLoginAttempts", 5)
160-
});
160+
new OrmLiteAuthRepository(c.Resolve<IDbConnectionFactory>()));
161161

162162
container.Resolve<IUserAuthRepository>().InitSchema();
163163
```
164164

165-
Which will make use of the existing OrmLite ConnectionFactory and set a default **MaxLoginAttempts** of **5** (overridable in AppSettings).
166-
`InitSchema()` is the convention used in ServiceStack to create any necessary RDBMS tables if they don't already exist.
165+
Which will make use of the existing registered OrmLite ConnectionFactory and run `InitSchema()`,
166+
the convention used in ServiceStack to create any necessary RDBMS tables if they don't already exist.
167+
It's safe to always call `InitSchema()` when available as it's just a NoOP for providers that don't require an implementation.
167168

168169
We also want to store User Sessions in OrmLite so that AppDomain reloads doesn't clear UserSessions in the Memory cache and force users to sign-in again.
169170
We can register to use an `OrmLiteCacheClient` and create any necessary tables with the registration below:

src/BenchmarksAnalyzer.ServiceInterface/BenchmarksAnalyzer.ServiceInterface.csproj

Lines changed: 20 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -30,33 +30,33 @@
3030
<WarningLevel>4</WarningLevel>
3131
</PropertyGroup>
3232
<ItemGroup>
33-
<Reference Include="Ionic.Zip, Version=1.9.3.0, Culture=neutral, processorArchitecture=MSIL">
34-
<SpecificVersion>False</SpecificVersion>
35-
<HintPath>..\packages\DotNetZip.1.9.3\lib\net20\Ionic.Zip.dll</HintPath>
33+
<Reference Include="Ionic.Zip, Version=1.9.6.0, Culture=neutral, PublicKeyToken=6583c7c814667745, processorArchitecture=MSIL">
34+
<HintPath>..\packages\DotNetZip.1.9.6\lib\net20\Ionic.Zip.dll</HintPath>
35+
<Private>True</Private>
3636
</Reference>
37-
<Reference Include="ServiceStack, Version=4.0.39.0, Culture=neutral, processorArchitecture=MSIL">
38-
<SpecificVersion>False</SpecificVersion>
39-
<HintPath>..\packages\ServiceStack.4.0.39\lib\net40\ServiceStack.dll</HintPath>
37+
<Reference Include="ServiceStack, Version=4.0.46.0, Culture=neutral, processorArchitecture=MSIL">
38+
<HintPath>..\packages\ServiceStack.4.0.46\lib\net40\ServiceStack.dll</HintPath>
39+
<Private>True</Private>
4040
</Reference>
41-
<Reference Include="ServiceStack.Client, Version=4.0.39.0, Culture=neutral, processorArchitecture=MSIL">
42-
<SpecificVersion>False</SpecificVersion>
43-
<HintPath>..\packages\ServiceStack.Client.4.0.39\lib\net40\ServiceStack.Client.dll</HintPath>
41+
<Reference Include="ServiceStack.Client, Version=4.0.46.0, Culture=neutral, processorArchitecture=MSIL">
42+
<HintPath>..\packages\ServiceStack.Client.4.0.46\lib\net40\ServiceStack.Client.dll</HintPath>
43+
<Private>True</Private>
4444
</Reference>
45-
<Reference Include="ServiceStack.Common, Version=4.0.39.0, Culture=neutral, processorArchitecture=MSIL">
46-
<SpecificVersion>False</SpecificVersion>
47-
<HintPath>..\packages\ServiceStack.Common.4.0.39\lib\net40\ServiceStack.Common.dll</HintPath>
45+
<Reference Include="ServiceStack.Common, Version=4.0.46.0, Culture=neutral, processorArchitecture=MSIL">
46+
<HintPath>..\packages\ServiceStack.Common.4.0.46\lib\net40\ServiceStack.Common.dll</HintPath>
47+
<Private>True</Private>
4848
</Reference>
4949
<Reference Include="ServiceStack.Interfaces, Version=4.0.0.0, Culture=neutral, PublicKeyToken=e06fbc6124f57c43, processorArchitecture=MSIL">
50-
<SpecificVersion>False</SpecificVersion>
51-
<HintPath>..\packages\ServiceStack.Interfaces.4.0.39\lib\portable-wp80+sl5+net40+win8+monotouch+monoandroid\ServiceStack.Interfaces.dll</HintPath>
50+
<HintPath>..\packages\ServiceStack.Interfaces.4.0.46\lib\portable-wp80+sl5+net40+win8+monotouch+monoandroid+xamarin.ios10\ServiceStack.Interfaces.dll</HintPath>
51+
<Private>True</Private>
5252
</Reference>
53-
<Reference Include="ServiceStack.OrmLite, Version=4.0.39.0, Culture=neutral, processorArchitecture=MSIL">
54-
<SpecificVersion>False</SpecificVersion>
55-
<HintPath>..\packages\ServiceStack.OrmLite.4.0.39\lib\net45\ServiceStack.OrmLite.dll</HintPath>
53+
<Reference Include="ServiceStack.OrmLite, Version=4.0.46.0, Culture=neutral, processorArchitecture=MSIL">
54+
<HintPath>..\packages\ServiceStack.OrmLite.4.0.46\lib\net45\ServiceStack.OrmLite.dll</HintPath>
55+
<Private>True</Private>
5656
</Reference>
57-
<Reference Include="ServiceStack.Text, Version=4.0.39.0, Culture=neutral, processorArchitecture=MSIL">
58-
<SpecificVersion>False</SpecificVersion>
59-
<HintPath>..\packages\ServiceStack.Text.4.0.39\lib\net40\ServiceStack.Text.dll</HintPath>
57+
<Reference Include="ServiceStack.Text, Version=4.0.46.0, Culture=neutral, processorArchitecture=MSIL">
58+
<HintPath>..\packages\ServiceStack.Text.4.0.46\lib\net40\ServiceStack.Text.dll</HintPath>
59+
<Private>True</Private>
6060
</Reference>
6161
<Reference Include="System" />
6262
<Reference Include="System.Core" />
Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,10 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
3-
<package id="DotNetZip" version="1.9.3" targetFramework="net45" />
4-
<package id="ServiceStack" version="4.0.39" targetFramework="net45" />
5-
<package id="ServiceStack.Client" version="4.0.39" targetFramework="net45" />
6-
<package id="ServiceStack.Common" version="4.0.39" targetFramework="net45" />
7-
<package id="ServiceStack.Interfaces" version="4.0.39" targetFramework="net45" />
8-
<package id="ServiceStack.OrmLite" version="4.0.39" targetFramework="net45" />
9-
<package id="ServiceStack.Text" version="4.0.39" targetFramework="net45" />
3+
<package id="DotNetZip" version="1.9.6" targetFramework="net45" />
4+
<package id="ServiceStack" version="4.0.46" targetFramework="net45" />
5+
<package id="ServiceStack.Client" version="4.0.46" targetFramework="net45" />
6+
<package id="ServiceStack.Common" version="4.0.46" targetFramework="net45" />
7+
<package id="ServiceStack.Interfaces" version="4.0.46" targetFramework="net45" />
8+
<package id="ServiceStack.OrmLite" version="4.0.46" targetFramework="net45" />
9+
<package id="ServiceStack.Text" version="4.0.46" targetFramework="net45" />
1010
</packages>

src/BenchmarksAnalyzer.ServiceModel/BenchmarksAnalyzer.ServiceModel.csproj

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,12 +31,12 @@
3131
</PropertyGroup>
3232
<ItemGroup>
3333
<Reference Include="ServiceStack.Interfaces, Version=4.0.0.0, Culture=neutral, PublicKeyToken=e06fbc6124f57c43, processorArchitecture=MSIL">
34-
<SpecificVersion>False</SpecificVersion>
35-
<HintPath>..\packages\ServiceStack.Interfaces.4.0.39\lib\portable-wp80+sl5+net40+win8+monotouch+monoandroid\ServiceStack.Interfaces.dll</HintPath>
34+
<HintPath>..\packages\ServiceStack.Interfaces.4.0.46\lib\portable-wp80+sl5+net40+win8+monotouch+monoandroid+xamarin.ios10\ServiceStack.Interfaces.dll</HintPath>
35+
<Private>True</Private>
3636
</Reference>
37-
<Reference Include="ServiceStack.Text, Version=4.0.39.0, Culture=neutral, processorArchitecture=MSIL">
38-
<SpecificVersion>False</SpecificVersion>
39-
<HintPath>..\packages\ServiceStack.Text.4.0.39\lib\net40\ServiceStack.Text.dll</HintPath>
37+
<Reference Include="ServiceStack.Text, Version=4.0.46.0, Culture=neutral, processorArchitecture=MSIL">
38+
<HintPath>..\packages\ServiceStack.Text.4.0.46\lib\net40\ServiceStack.Text.dll</HintPath>
39+
<Private>True</Private>
4040
</Reference>
4141
<Reference Include="System" />
4242
<Reference Include="System.Core" />
Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<packages>
3-
<package id="ServiceStack.Interfaces" version="4.0.39" targetFramework="net45" />
4-
<package id="ServiceStack.Text" version="4.0.39" targetFramework="net45" />
3+
<package id="ServiceStack.Interfaces" version="4.0.46" targetFramework="net45" />
4+
<package id="ServiceStack.Text" version="4.0.46" targetFramework="net45" />
55
</packages>

0 commit comments

Comments
 (0)