[OPENAM-5430] REST PUT create realm makes 400 if I provide "If-None-Match: *" in the request Created: 20/Jan/15  Updated: 14/Sep/15  Resolved: 14/Sep/15

Status: Resolved
Project: OpenAM
Component/s: rest
Affects Version/s: 12.0.0, 12.0.1, 13.0.0
Fix Version/s: 12.0.3, 13.0.0

Type: Bug Priority: Major
Reporter: Richard Hruza Assignee: Quentin CASTEL [X] (Inactive)
Resolution: Fixed Votes: 0
Labels: EDISON
Remaining Estimate: 1h
Time Spent: 1h
Original Estimate: 2h
Environment:

OpenAM 13.0.0-SNAPSHOT Build 12122 (2015-January-20 02:39)


Issue Links:
Relates
is related to OPENAM-5463 REST PUT - realm is created without p... Resolved
is related to OPENAM-5506 Missing header "If-None-Match: *" for... Closed
Target Version/s:
Rank: 1|hzlhc7:
Sprint: Sprint 78 - Team Newton, Sustaining Sprint 12
QA Assignee: Richard Hruza
Verified Version/s:

 Description   

REST PUT create realm makes 400 if I provide "If-None-Match: *" in the request

STEP TO REPRODUCE:
1. Create a realm

curl --request PUT --header "iPlanetDirectoryPro: <ADMIN TOKEN>" --header "Content-Type: application/json" --header "If-None-Match: *" --data '{ }' "http://centos6-64.example.com:8080/openam/json/realms/testRealm?_prettyPrint=true"

Observed result:

{
  "code" : 400,
  "reason" : "Bad Request",
  "message" : "Bad Request"
}

Expected result:

{
  "realmCreated" : "/testRealm"
}

I am able to create a realm, if I don't provide "If-None-Match: *" header.

After fix, please pass this issue to doc.:
http://openam.forgerock.org/openam-documentation/openam-doc-source/doc/dev-guide/index.html#rest-api-create-realm



 Comments   
Comment by David Luna [ 29/Jan/15 ]

cr-5430

Comment by David Luna [ 03/Feb/15 ]

svn 12313

Comment by Richard Hruza [ 04/Feb/15 ]

Tested with: OpenAM 13.0.0-SNAPSHOT Build 12328 (2015-February-04 02:47)

curl --request PUT --header "iPlanetDirectoryPro: <ADMIN TOKEN>" --header "Content-Type: application/json" --header "If-None-Match: *" --data '{ }' "http://riso-centos7.test.forgerock.com:8080/openam/json/realms/testRealm?_prettyPrint=true"

{
  "realmCreated" : "/testRealm"
}
Comment by Nemanja Lukic [ 04/May/15 ]

Reopening as the issue persists on 12.0.1

Comment by Quentin CASTEL [X] (Inactive) [ 14/Sep/15 ]

Fixed in 12.0.2 r15675

Generated at Fri Mar 05 07:04:42 UTC 2021 using Jira 7.13.12#713012-sha1:6e07c38070d5191bbf7353952ed38f111754533a.