Javascript 如何通过wireshark(google auth)捕获OAuth2协议

Javascript 如何通过wireshark(google auth)捕获OAuth2协议,javascript,node.js,oauth-2.0,Javascript,Node.js,Oauth 2.0,我试图通过wireshark捕获OAuth2协议。 “获取授权代码”已被捕获,但“exchange访问令牌”未被捕获 访问令牌和用户配置文件应该在Get/profile\u Google之前捕获,我应该怎么做 这是我的密码: SCOPE=[]https://www.googleapis.com/auth/userinfo.email', 'https://www.googleapis.com/auth/userinfo.profile'] passport.use(谷歌新战略)({ clie

我试图通过wireshark捕获OAuth2协议。 “获取授权代码”已被捕获,但“exchange访问令牌”未被捕获

访问令牌和用户配置文件应该在
Get/profile\u Google
之前捕获,我应该怎么做

这是我的密码:

SCOPE=[]https://www.googleapis.com/auth/userinfo.email', 
'https://www.googleapis.com/auth/userinfo.profile']
passport.use(谷歌新战略)({
clientID:process.env.GOOGLE\u CLIENT\u ID,
clientSecret:process.env.GOOGLE\u CLIENT\u SECRET,
callbackURL:process.env.CALLBACK\u GOOGLE\u URL
},
函数(accessToken、refreshToken、配置文件、cb){
token=accessToken;
log('accessToken:'+accessToken);
log('refreshToken:'+refreshToken);
console.log('profile:'+profile);
返回cb(空,配置文件);
}
));
app.get('/auth/google',passport.authenticate('google',{scope:scope}));
app.get('/auth/google/callback',passport.authenticate('google',{failureRedirect:'/failed'}),
功能(req、res){
res.redirect('/profile_Google');
}
);
app.get('/profile_Google',checkUserLoggedIn,(req,res)=>{
console.log('In profile_Google')
设img=“”;
html=`${req.user.id}
${req.user.displayName}
${req.user.emails[0].value}
`+img;
res.send(html+成功)
});
});