fenixblades
ADFS - only show certain claims provider trusts for ONE relying party and not all of them?
I have the following sites:
Right now if I go to https://example.com/ClientA then I'm sent to
https://adfsco.example.com/adfs/ls?...
and there is the claims providers we trust for that site.
Now I'd like to have it so when https://example.com/ClientB is navigated to, the user would see different providers that only matter for that site.
I've seen things about home realm discovery pages, but no step-by-step guide explaining how to actually wire this up. I'm assuming one ADFS can handle this, but not sure how. Is this where relying parties come in?1 replies
❔ IIS urlrewrite not working
I have a simple web.config for an index.html page like this:
If I navigate to https://example.com/foo/REMOVE_ME then I get a 404 because /foo/REMOVE_ME is not a valid resource.
I feel like this rewrite is very simple and should be correct, but I'm clearly missing something. Any ideas?
Note, this is on a web app on my site. So the site is example.com and the web app is foo. IIS treeview looks like this:
2 replies
❔ Serilog file sink from multiple servers has interleaved messages
I have a web app deployed across 10 web servers. They are all configured as such (note, the
path
below is a shared network path. So they are all pointing to the same log file):
However I'm noticing the log file has interleaved messages:
2023-02-28 00:03:16.105 -06:00 [DBG] Execution plan of result filters (in the following order): ["Microsoft.AspNetCore.Mvc.Infrastructure.C2023-02-28 00:03:16.054 -06:00 [INF] Requ2023-02-28 00:03:16.130 -06:00 [DBG] Execution plan of result filters (in the following order):Notice the
[DBG]
and [INF]
log levels in the same message, and this here here specifically:
Infrastructure.C2023-02-28 00:03:16.054 -06:00 [INF] Requ2023-02-28 00:03:16.13How can I prevent this from happening? I thought
shared: true
was the support Serilog needed to handle this situation?10 replies
❔ Log from helper class without creating new context? (Serilog)
I have a bunch of services with their own dedicated loggers that have config'd settings for filtering based on that exact type:
This way, I can setup output log files for each service individually.
Now I have a helper class that all of the services utilize, and I want to add logging to this helper class, but I want the logs to appear in the log file that the calling service already has going. Since the filtering above is based on type, I'm not sure how to wire this up.
Right now my helper class is setup to use DI like:
But this seems to create a new logger for
Helper
specifically, which isn't caught by the calling service's logger filtering.5 replies
✅ Any modern approach to getting the calling class typename aside from using the stack frame?
10 years ago I used to use the stack frame to go backwards and get what class is calling my current method. I know there's attributes as well, but they are more physical file based. Is there a modern approach in current .NET to getting this information at runtime? Such as for a logger method that's trying to find out what called it?
5 replies
❔ Why wont visual studio auto format this with CTRL K + CTRL D?
can anyone think of why visual studio wont format these lambda arrows with
CTRL K + CTRL D
but it will format things around it like spacing between semicolons?
if i do something like this
it correctly auto formats it to
so im not sure what the difference is in context between those 2 that would cause visual studio to not format the first instance.4 replies