fiddler - Capture HTTPS request to nonexistent server with FiddlerCore -
i try response https request, using fiddlercore. need things work that: put fake url in browser, https://my_url_that_doesnt_exist.com/
intercept request fiddlercore , respons data. see connect , host url. know, due https , fiddler proxy. there way real url , able respond https request, using fiddler core?
also use code create root certificate if missing:
if (!fiddler.certmaker.rootcertexists()) { if (!fiddler.certmaker.createrootcert()) { throw new exception("could not create certificate."); } }
also use startup settings:
fiddlercorestartupflags fcsf = fiddlercorestartupflags.default | fiddlercorestartupflags.decryptssl|fiddlercorestartupflags.allowremoteclients;
and config.ignoreservercerterrors = true;
this https request not visible in fiddler itself. mean if try non-existing url id app respond custom content. http, not https , fiddler contain following in response: [fiddler] dns lookup "my_url_that_doesnt_exist.com" failed. requested name valid, no data of requested type found
but if use existing https url, google plus or can see https , request details.
so question follows: how can intercept https request non existing url , serve content instead? can provide additional details if needed.
also makecert.exe in same folder binaries are.
the problem https traffic flows through connect tunnel, , default secure traffic won't sent if creating connect tunnel target server doesn't first succeed. of course, if target server doesn't exist, end dns error in creating tunnel, secure requests never sent.
the workaround tell fiddler tell client connect tunnel created, without trying contact server. adding inside beforerequest
handler:
if (osession.httpmethodis("connect")) { osession.oflags["x-replywithtunnel"] = "generatetunnel"; return; }
Comments
Post a Comment