Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<ItemGroup>
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly" Version="6.0.0" />
<PackageReference Include="Microsoft.AspNetCore.Components.WebAssembly.DevServer" Version="6.0.0" PrivateAssets="all" />
<PackageReference Include="PostSharp" Version="2023.0.3" />
<PackageReference Include="PostSharp" Version="2024.0.5" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,10 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="System.ValueTuple">
<Version>4.5.0</Version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -59,13 +59,13 @@
<Version>4.7.0</Version>
</PackageReference>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics.CommonLogging">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="System.ValueTuple">
<Version>4.5.0</Version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,10 +53,10 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="System.ValueTuple">
<Version>4.5.0</Version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,10 +57,10 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="ServiceStack.Common">
<Version>5.13.2</Version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -58,10 +58,10 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="System.ValueTuple">
<Version>4.5.0</Version>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<TargetFramework>netcoreapp2.1</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
<Configurations>Debug;Release;Development</Configurations>
<Platforms>AnyCPU</Platforms>
</PropertyGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
<Project>
<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>netcoreapp3.1</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
<LangVersion>7.3</LangVersion>
<Platforms>AnyCPU</Platforms>
<Configurations>Debug;Release;Development</Configurations>
<PostSharpBuild Condition="'$(Configuration)'=='Development'">Debug</PostSharpBuild>
</PropertyGroup>
<Import Project="Sdk.props" Sdk="Microsoft.NET.Sdk" />
<ItemGroup>
<PackageReference Include="PostSharp.Patterns.Diagnostics.HttpClient" Version="2023.0.3" />
<PackageReference Include="PostSharp.Patterns.Diagnostics.HttpClient" Version="2024.0.5" />
<PackageReference Include="Serilog.Extensions.Logging" Version="3.1.0" />
<PackageReference Include="Serilog.Sinks.Console" Version="4.0.1" />
<PackageReference Include="PostSharp.Patterns.Diagnostics" Version="2023.0.3" />
<PackageReference Include="PostSharp.Patterns.Diagnostics.Serilog" Version="2023.0.3" />
<PackageReference Include="PostSharp.Patterns.Diagnostics" Version="2024.0.5" />
<PackageReference Include="PostSharp.Patterns.Diagnostics.Serilog" Version="2024.0.5" />
<PackageReference Include="Serilog.Sinks.ElasticSearch" Version="8.4.1" />
</ItemGroup>
<Import Project="Sdk.targets" Sdk="Microsoft.NET.Sdk" />
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<Project>
<Import Project="Sdk.props" Sdk="Microsoft.NET.Sdk.Web" />
<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
<LangVersion>7.3</LangVersion>
<OutputType>Exe</OutputType>
<Configurations>Debug;Release;Development</Configurations>
Expand All @@ -14,9 +14,9 @@
<ItemGroup>
<PackageReference Include="Serilog.AspNetCore" Version="4.1.0" />
<PackageReference Include="Serilog.Sinks.Console" Version="4.0.1" />
<PackageReference Include="PostSharp.Patterns.Diagnostics" Version="2023.0.3" />
<PackageReference Include="PostSharp.Patterns.Diagnostics.Serilog" Version="2023.0.3" />
<PackageReference Include="PostSharp.Patterns.Diagnostics.AspNetCore" Version="2023.0.3" />
<PackageReference Include="PostSharp.Patterns.Diagnostics" Version="2024.0.5" />
<PackageReference Include="PostSharp.Patterns.Diagnostics.Serilog" Version="2024.0.5" />
<PackageReference Include="PostSharp.Patterns.Diagnostics.AspNetCore" Version="2024.0.5" />
<PackageReference Include="Serilog.Sinks.ElasticSearch" Version="8.4.1" />
</ItemGroup>
<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,18 +1,18 @@
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="Elmah.Io.AspNetCore.Serilog">
<Version>4.0.10</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics.Serilog">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="Serilog.Sinks.ColoredConsole">
<Version>3.0.1</Version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -54,13 +54,13 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics.Tracing">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="System.ValueTuple">
<Version>4.5.0</Version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -53,13 +53,13 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics.Tracing">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="System.ValueTuple">
<Version>4.5.0</Version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,13 @@
<Version>2.0.13</Version>
</PackageReference>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics.Log4Net">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="System.ValueTuple">
<Version>4.5.0</Version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,10 @@
<Version>4.10.17</Version>
</PackageReference>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="System.ValueTuple">
<Version>4.5.0</Version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,13 +61,13 @@
<Version>4.7.12</Version>
</PackageReference>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics.NLog">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="System.ValueTuple">
<Version>4.5.0</Version>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<Project Sdk="Microsoft.NET.Sdk.Web">

<PropertyGroup>
<TargetFramework>netcoreapp3.1</TargetFramework>
<TargetFramework>net6.0</TargetFramework>
</PropertyGroup>

<ItemGroup>
<PackageReference Include="PostSharp.Patterns.Diagnostics" Version="2023.0.3" />
<PackageReference Include="PostSharp.Patterns.Diagnostics.AspNetCore" Version="2023.0.3" />
<PackageReference Include="PostSharp.Patterns.Diagnostics.Configuration" Version="2023.0.3" />
<PackageReference Include="PostSharp.Patterns.Diagnostics" Version="2024.0.5" />
<PackageReference Include="PostSharp.Patterns.Diagnostics.AspNetCore" Version="2024.0.5" />
<PackageReference Include="PostSharp.Patterns.Diagnostics.Configuration" Version="2024.0.5" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -53,13 +53,13 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="PostSharp.Patterns.Diagnostics.Serilog">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="Serilog">
<Version>2.10.0</Version>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using PostSharp.Aspects;
using PostSharp.Serialization;
using System;
using System.Collections;
using System.Collections.Generic;
Expand All @@ -10,7 +11,7 @@ namespace PostSharp.Samples.Authorization.Framework
/// <summary>
/// Base class for <see cref="MethodAuthorizationAspect" /> and <see cref="LocationAuthorizationAspect" />.
/// </summary>
[Serializable]
[PSerializable]
public abstract class AuthorizationAspect : IAspect
{
[ThreadStatic] private static bool evaluatingPermissions;
Expand Down Expand Up @@ -152,7 +153,7 @@ internal void RequirePermission(MemberInfo member, OperationSemantic semantic, i
}


[Serializable]
[PSerializable]
private struct OperationPermission<T>
{
public OperationPermission(OperationSemantic semantic, int parameterIndex, T permission)
Expand All @@ -162,11 +163,11 @@ public OperationPermission(OperationSemantic semantic, int parameterIndex, T per
ParameterIndex = parameterIndex;
}

public OperationSemantic Semantic { get; }
public OperationSemantic Semantic { get; private set; }

public int ParameterIndex { get; }
public int ParameterIndex { get; private set; }

public T Permission { get; }
public T Permission { get; private set; }
}
}
}
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
using PostSharp.Aspects;
using PostSharp.Aspects.Dependencies;
using PostSharp.Reflection;
using PostSharp.Serialization;
using System;
using System.Reflection;

Expand All @@ -14,7 +15,7 @@ namespace PostSharp.Samples.Authorization.Framework
/// Note that this aspect is not a custom attribute and cannot be applied directly to a field or a property. It is
/// indirectly created by the <see cref="RequiresPermissionAttribute" /> aspect.
/// </remarks>
[Serializable]
[PSerializable]
[AspectTypeDependency(AspectDependencyAction.Commute, typeof(LocationAuthorizationAspect))]
public class LocationAuthorizationAspect : AuthorizationAspect, ILocationInterceptionAspect
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using PostSharp.Aspects;
using PostSharp.Aspects.Dependencies;
using PostSharp.Serialization;
using System;
using System.Reflection;

Expand All @@ -12,7 +13,7 @@ namespace PostSharp.Samples.Authorization.Framework
/// Note that this aspect is not a custom attribute and cannot be applied directly to a field or a property. It is
/// indirectly created by the <see cref="RequiresPermissionAttribute" /> aspect.
/// </remarks>
[Serializable]
[PSerializable]
[AspectTypeDependency(AspectDependencyAction.Commute, typeof(MethodAuthorizationAspect))]
public class MethodAuthorizationAspect : AuthorizationAspect, IOnMethodBoundaryAspect
{
Expand Down
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
using System;
using PostSharp.Serialization;
using System;

namespace PostSharp.Samples.Authorization.Framework
{
Expand All @@ -9,11 +10,11 @@ namespace PostSharp.Samples.Authorization.Framework
/// <see cref="RequiresPermissionBaseAttribute" /> class,
/// which is limited to standard permissions or simple named permsissions.
/// </summary>
[Serializable]
[PSerializable]
public class RequiresPermissionAttribute : RequiresPermissionBaseAttribute
{
private readonly string _defaultPermission;
private readonly string _writePermission;
private string _defaultPermission;
private string _writePermission;

/// <summary>
/// Initializes a new <see cref="RequiresPermissionAttribute" /> with a single <see cref="StandardPermission" />. This
Expand Down
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using PostSharp.Aspects;
using PostSharp.Extensibility;
using PostSharp.Serialization;
using System;
using System.Collections.Generic;
using System.Linq;
Expand All @@ -13,7 +14,7 @@ namespace PostSharp.Samples.Authorization.Framework
/// object.
/// It could be used to implementation for instance parametric permissions.
/// </summary>
[Serializable]
[PSerializable]
[AttributeUsage(AttributeTargets.Field | AttributeTargets.Property | AttributeTargets.Method | AttributeTargets.Parameter, AllowMultiple = true)]
public abstract class RequiresPermissionBaseAttribute : Attribute, IPermissionFactory, IAspectProvider
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,7 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
<PackageReference Include="System.Collections.Immutable">
<Version>6.0.0</Version>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@
</ItemGroup>
<ItemGroup>
<PackageReference Include="PostSharp">
<Version>2023.0.3</Version>
<Version>2024.0.5</Version>
</PackageReference>
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
Expand Down
Loading