My punny title is referencing to “fiddle with something in an unskilled and unsuccessful effort”. I’m actually decently experienced with both Fiddler and PowerShell, but not together. And this seems like a great opportunity to make fun of myself a little.
I could not connect to Microsoft Purview (Compliance center) via PowerShell. And for the love of GOD, I couldn’t understand why it didn’t work. I even asked my coworker to connect, and it worked splendidly. So I restarted my computer, but it still didn’t work. I started Fiddler to see why it wasn’t working.
BOOM, now everything worked!
💡 Now, it all started to come back to me…
While running PnP PowerShell, I received some bizarre non-descriptive errors that made no sense. To understand further, I decided to open Fiddler to inspect the traffic. Maybe there are more intelligent ways, but I ran the following script to route PowerShell to Fiddler’s default listening port.
netsh winhttp set proxy localhost:8888
The problem was that I didn’t remember to reset this afterward, so my PowerShell needed Fiddler in order to work.
At least my coworker didn’t laugh (too hard) at me! He instead kindly reminded me to reset the proxy.
This is how you do that:
netsh winhttp reset proxy
And now everything works as intended and I can conntect to Microsoft Purview once again!
Lesson learned. And lessons we learn, we pass along.
Sincerery
/Your noob