Middleware component which adds a the remote IP id as a claim urn:be:vlaanderen:vbr:ip
for the user on the request context.
The claim name is configurable as well.
public void Configure(IApplicationBuilder app, ...)
{
app
...
.UseMiddleware<AddRemoteIpAddressMiddleware>()
...
}
public void Configure(IApplicationBuilder app, ...)
{
app
...
.UseMiddleware<AddRemoteIpAddressMiddleware>("urn:custom-claim:ip")
...
}