PHPFixing
  • Privacy Policy
  • TOS
  • Ask Question
  • Contact Us
  • Home
  • PHP
  • Programming
  • SQL Injection
  • Web3.0

Saturday, August 6, 2022

[FIXED] how to config apache jmeter 2.6 oauth 2.0

 August 06, 2022     jmeter, oauth, oauth-2.0     No comments   

Issue

I need to perform tests using jmeter for an oauth 2.0 secured API. I have found the following plugin

http://code.google.com/p/jmeter-oauth/

I managed to successfully install it but now I am stuck with actually writing the tests. The documentation is missing....does anyone have a clue on how to actually use the plugin ?

Thanks.


Solution

Is your problem in JMeter OAuth Sampler usage - or in OAuth protocol testing strategy itself?

What's wrong with JMeter OAuth Sampler guide on plugin's site?

Beware only that sampler could not work or work not properly with Jmeter versions 2.5.x/2.6 - see related issue.
You can also use OAuth Test Client for additional verification.

UPDATED:

Again, use OAuth Test Client with any HTTP analyzer (HttpFox is good one) to study interaction using OAuth protocol - in this case with OAuth Test Server.

Here you'll find description of all the steps of interaction that are easily mapped onto sampler on the picture in JMeter OAuth Sampler guide:

  1. Getting a Request Token ("Authentication" sampler on the picture). Here you have to extract oauth_token and oauth_token_secret from successfull response to use further in OAuth Sampler:

    oauth_token=requestkey&oauth_token_secret=requestsecret

    Corresponding extractors are displayed as children of Authentication sampler.

  2. Getting an Access Token ("Token Validation")

  3. Get Data ("Get Data" OAuth Sampler on the picture).

Find protocol flow and specification here.

Here ${oauth_token} and ${token_secret} are extracted from the 1st sampler's response.



Answered By - Aliaksandr Belik
Answer Checked By - Pedro (PHPFixing Volunteer)
  • Share This:  
  •  Facebook
  •  Twitter
  •  Stumble
  •  Digg
Newer Post Older Post Home

0 Comments:

Post a Comment

Note: Only a member of this blog may post a comment.

Total Pageviews

Featured Post

Why Learn PHP Programming

Why Learn PHP Programming A widely-used open source scripting language PHP is one of the most popular programming languages in the world. It...

Subscribe To

Posts
Atom
Posts
Comments
Atom
Comments

Copyright © PHPFixing