Fiddler

只能记录,参考链接: https://www.cnblogs.com/yyhh/p/5140852.html

Fiddler是一款蛮好用的抓包工具

1.Fiddler打开后自动会更改浏览器的代理,fiddler关闭后又自动还原浏览器代理

参考如下win10:

 

 2.java代码访问http接口走fiddler

參考如下代码:

RestTemplate restTemplate = builder.build();
SimpleClientHttpRequestFactory requestFactory = new SimpleClientHttpRequestFactory();
        requestFactory.setProxy(
                new Proxy(Proxy.Type.HTTP, new InetSocketAddress("localhost", 8888))
        );
restTemplate.setRequestFactory(requestFactory);
Map<String,String> resp2 = restTemplate.postForObject(serviceUrl, params2,Map.class);

 

posted @ 2021-09-01 11:16  宅山仔  阅读(76)  评论(0编辑  收藏  举报