title: Capture WebDriver requests in Jmeter
body: <p>One of the services I gonna test using Jmeter has complex authorization mechanism that requires some CS-based steps (JavaScript). So, to set up a session, I have to use WebDriver as Jmeter can't (and actually shouldn't) process JS.</p>
  
  <p>I do it in the following way: at the beginning of each thread I open the resource in real browser (via Jmeter WebDriver plugin), complete authorization, store browser cookies that was set up by server and then use these cookies to generate load using standard Jmeter logic within defined HTTP-session.</p>
  
  <p>This schema works fine and I successfully use it in different load tests.</p>
  
  <p>But now the service I test requires not only cookies but also some important parameters that browser sends in POST as a part of authorization process. To prove that my requests belong to the same session, I should extract some sensitive parameters not from response (it can be easily done) but from <strong>request</strong>.
  I can't find these values stored anywhere in DOM and it seems like these values are generated by JS attached to response page.</p>
  
  <p>So, my question is: <strong>is there a way to capture parameters from request sent by WebDriver?</strong> </p>
  
  <p>I understand that all requests done by browser initiated in Jmeter are not visible to it. And the only idea I see is to use Jmeter request recorder dynamically:</p>
  
  <ol>
  <li><p>Open browser window.</p></li>
  <li><p>Define Jmeter as a proxy for this browser.</p></li>
  <li><p>Capture requests sent by browser in Jmeter using recorder.</p></li>
  <li><p>Somehow extract sensitive data from requests.</p></li>
  <li><p>Use the data to generate load.</p></li>
  </ol>
  
  <p>Any ideas appreciated. Thanks in advance!</p>