I've been trying to get some more complex claims transformations working lately between Azure AD, Sitecore Identity, and Sitecore 9.1. Unfortunately, it was difficult to see if my transforms were working, if AD was passing the claims I thought they were, and if my mappings were correct. I whipped up a quick utility that can be used on your Sitecore server to output claims to the log as they come in for debugging – SI Snitch.
This post is part of a series on configuring Sitecore Identity and Azure AD. You can view all posts in this series, covering setup to configuration, here.
The code is nothing special, but if you're stuck in a similar situation, it could save you the hour or two of wiring up something similar. All claims from your SI server will be dumped to the log for inspection. It helped me catch a few instances of close-but-not-quite claims transformations, and to ensure my configs were correct on the SI side.
Code's over at github – if you run in to an issue, let me know or add an issue in the repo.
Edit: Robbert Hock has forked this project and, to date, has produced versions for Sitecore 9.3 and Sitecore 10. Please visit his repository here for those versions, as well as his blog post on SI Snitch. Thank you Robbert!