FA-27851 / HTTP redirects / Open access
Select an unambiguous Location field without losing raw syntax: outer ows · case 01
Whitespace trimming corrupts internal target characters.
ROOT CAUSE
The outer-ows decision uses "[v for k,v in lines if k.lower() == 'location']"; this violates the stipulated controller policy.
VERIFIED REPAIR
At this decision use "[v.strip(' \\t') for k,v in lines if k.lower() == 'location']", preserving the other controller outputs.
Unsuccessful approach: The partial repair uses "[v.replace(' ', '').replace('\\t','') for k,v in lines if k.lower() == 'location']" and still fails an explicit boundary or control.
Case contract
Select an unambiguous Location field without losing raw syntax. The explicit fixture inputs and outputs define a bounded offline policy; request identity must accompany the decision.
Why this case matters
Models a redirect controller decision before following a target or exposing a redirect result.
1 / The failure
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
from urllib.parse import urlsplit, unquote, quote
import posixpath
import re
N = 1
observations = []
def solve(request, lines):
return {'request': request, 'decision': [[v for k,v in lines if k.lower() == 'location'], len([v for k,v in lines if k.lower() == 'location']) > 1, [v for k,v in lines if k.lower() == 'location'], [v for k,v in lines if k.lower() == 'location'], 'missing' if not any(k.lower() == 'location' for k,v in lines) else 'present']}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve('/requests/' + str(N) + '/0', [('Location', ' /a,b '), ('X', 'z')]), {'request': '/requests/' + str(N) + '/0', 'decision': [[' /a,b '], False, ['/a,b'], [' /a,b '], 'present']})
check('fixture 2', solve('/requests/' + str(N) + '/1', [('location', '/a b')]), {'request': '/requests/' + str(N) + '/1', 'decision': [['/a b'], False, ['/a b'], ['/a b'], 'present']})
check('fixture 3', solve('/requests/' + str(N) + '/2', [('LOCATION', '')]), {'request': '/requests/' + str(N) + '/2', 'decision': [[''], False, [''], [''], 'present']})
check('fixture 4', solve('/requests/' + str(N) + '/3', [('X', 'z')]), {'request': '/requests/' + str(N) + '/3', 'decision': [[], False, [], [], 'missing']})
check('fixture 5', solve('/requests/' + str(N) + '/4', [('Location', '/a'), ('location', '/b')]), {'request': '/requests/' + str(N) + '/4', 'decision': [['/a', '/b'], True, ['/a', '/b'], ['/a', '/b'], 'present']})
check('fixture 6', solve('/requests/' + str(N) + '/5', []), {'request': '/requests/' + str(N) + '/5', 'decision': [[], False, [], [], 'missing']})
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| fixture 1 | {'decision': [[' /a,b '], False, [' /a,b '], [' /a,b '], 'present'], 'request': '/requests/1/0'} | {'decision': [[' /a,b '], False, ['/a,b'], [' /a,b '], 'present'], 'request': '/requests/1/0'} | Failed |
| fixture 2 | {'decision': [['/a b'], False, ['/a b'], ['/a b'], 'present'], 'request': '/requests/1/1'} | {'decision': [['/a b'], False, ['/a b'], ['/a b'], 'present'], 'request': '/requests/1/1'} | Passed |
| fixture 3 | {'decision': [[''], False, [''], [''], 'present'], 'request': '/requests/1/2'} | {'decision': [[''], False, [''], [''], 'present'], 'request': '/requests/1/2'} | Passed |
| fixture 4 | {'decision': [[], False, [], [], 'missing'], 'request': '/requests/1/3'} | {'decision': [[], False, [], [], 'missing'], 'request': '/requests/1/3'} | Passed |
| fixture 5 | {'decision': [['/a', '/b'], True, ['/a', '/b'], ['/a', '/b'], 'present'], 'request': '/requests/1/4'} | {'decision': [['/a', '/b'], True, ['/a', '/b'], ['/a', '/b'], 'present'], 'request': '/requests/1/4'} | Passed |
| fixture 6 | {'decision': [[], False, [], [], 'missing'], 'request': '/requests/1/5'} | {'decision': [[], False, [], [], 'missing'], 'request': '/requests/1/5'} | Passed |
SHA-256 / 45b7ce93831b3c71291f074dc09c3d700a1acea8b71da86e987586b1dfef0b45
2 / The unsuccessful fix
Exit 1"""Failure Map reference implementation. Python standard library only."""
import json
from urllib.parse import urlsplit, unquote, quote
import posixpath
import re
N = 1
observations = []
def solve(request, lines):
return {'request': request, 'decision': [[v for k,v in lines if k.lower() == 'location'], len([v for k,v in lines if k.lower() == 'location']) > 1, [v.replace(' ', '').replace('\t','') for k,v in lines if k.lower() == 'location'], [v for k,v in lines if k.lower() == 'location'], 'missing' if not any(k.lower() == 'location' for k,v in lines) else 'present']}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve('/requests/' + str(N) + '/0', [('Location', ' /a,b '), ('X', 'z')]), {'request': '/requests/' + str(N) + '/0', 'decision': [[' /a,b '], False, ['/a,b'], [' /a,b '], 'present']})
check('fixture 2', solve('/requests/' + str(N) + '/1', [('location', '/a b')]), {'request': '/requests/' + str(N) + '/1', 'decision': [['/a b'], False, ['/a b'], ['/a b'], 'present']})
check('fixture 3', solve('/requests/' + str(N) + '/2', [('LOCATION', '')]), {'request': '/requests/' + str(N) + '/2', 'decision': [[''], False, [''], [''], 'present']})
check('fixture 4', solve('/requests/' + str(N) + '/3', [('X', 'z')]), {'request': '/requests/' + str(N) + '/3', 'decision': [[], False, [], [], 'missing']})
check('fixture 5', solve('/requests/' + str(N) + '/4', [('Location', '/a'), ('location', '/b')]), {'request': '/requests/' + str(N) + '/4', 'decision': [['/a', '/b'], True, ['/a', '/b'], ['/a', '/b'], 'present']})
check('fixture 6', solve('/requests/' + str(N) + '/5', []), {'request': '/requests/' + str(N) + '/5', 'decision': [[], False, [], [], 'missing']})
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| fixture 1 | {'decision': [[' /a,b '], False, ['/a,b'], [' /a,b '], 'present'], 'request': '/requests/1/0'} | {'decision': [[' /a,b '], False, ['/a,b'], [' /a,b '], 'present'], 'request': '/requests/1/0'} | Passed |
| fixture 2 | {'decision': [['/a b'], False, ['/ab'], ['/a b'], 'present'], 'request': '/requests/1/1'} | {'decision': [['/a b'], False, ['/a b'], ['/a b'], 'present'], 'request': '/requests/1/1'} | Failed |
| fixture 3 | {'decision': [[''], False, [''], [''], 'present'], 'request': '/requests/1/2'} | {'decision': [[''], False, [''], [''], 'present'], 'request': '/requests/1/2'} | Passed |
| fixture 4 | {'decision': [[], False, [], [], 'missing'], 'request': '/requests/1/3'} | {'decision': [[], False, [], [], 'missing'], 'request': '/requests/1/3'} | Passed |
| fixture 5 | {'decision': [['/a', '/b'], True, ['/a', '/b'], ['/a', '/b'], 'present'], 'request': '/requests/1/4'} | {'decision': [['/a', '/b'], True, ['/a', '/b'], ['/a', '/b'], 'present'], 'request': '/requests/1/4'} | Passed |
| fixture 6 | {'decision': [[], False, [], [], 'missing'], 'request': '/requests/1/5'} | {'decision': [[], False, [], [], 'missing'], 'request': '/requests/1/5'} | Passed |
SHA-256 / 76771aa20a2a60f62c4ab6d7e878bd88175008d623c6ff277a096617bf34f459
3 / The verified repair
Exit 0"""Failure Map reference implementation. Python standard library only."""
import json
from urllib.parse import urlsplit, unquote, quote
import posixpath
import re
N = 1
observations = []
def solve(request, lines):
return {'request': request, 'decision': [[v for k,v in lines if k.lower() == 'location'], len([v for k,v in lines if k.lower() == 'location']) > 1, [v.strip(' \t') for k,v in lines if k.lower() == 'location'], [v for k,v in lines if k.lower() == 'location'], 'missing' if not any(k.lower() == 'location' for k,v in lines) else 'present']}
def check(label, actual, expected):
observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('fixture 1', solve('/requests/' + str(N) + '/0', [('Location', ' /a,b '), ('X', 'z')]), {'request': '/requests/' + str(N) + '/0', 'decision': [[' /a,b '], False, ['/a,b'], [' /a,b '], 'present']})
check('fixture 2', solve('/requests/' + str(N) + '/1', [('location', '/a b')]), {'request': '/requests/' + str(N) + '/1', 'decision': [['/a b'], False, ['/a b'], ['/a b'], 'present']})
check('fixture 3', solve('/requests/' + str(N) + '/2', [('LOCATION', '')]), {'request': '/requests/' + str(N) + '/2', 'decision': [[''], False, [''], [''], 'present']})
check('fixture 4', solve('/requests/' + str(N) + '/3', [('X', 'z')]), {'request': '/requests/' + str(N) + '/3', 'decision': [[], False, [], [], 'missing']})
check('fixture 5', solve('/requests/' + str(N) + '/4', [('Location', '/a'), ('location', '/b')]), {'request': '/requests/' + str(N) + '/4', 'decision': [['/a', '/b'], True, ['/a', '/b'], ['/a', '/b'], 'present']})
check('fixture 6', solve('/requests/' + str(N) + '/5', []), {'request': '/requests/' + str(N) + '/5', 'decision': [[], False, [], [], 'missing']})
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
| Boundary fixture | Actual | Expected | Outcome |
|---|---|---|---|
| fixture 1 | {'decision': [[' /a,b '], False, ['/a,b'], [' /a,b '], 'present'], 'request': '/requests/1/0'} | {'decision': [[' /a,b '], False, ['/a,b'], [' /a,b '], 'present'], 'request': '/requests/1/0'} | Passed |
| fixture 2 | {'decision': [['/a b'], False, ['/a b'], ['/a b'], 'present'], 'request': '/requests/1/1'} | {'decision': [['/a b'], False, ['/a b'], ['/a b'], 'present'], 'request': '/requests/1/1'} | Passed |
| fixture 3 | {'decision': [[''], False, [''], [''], 'present'], 'request': '/requests/1/2'} | {'decision': [[''], False, [''], [''], 'present'], 'request': '/requests/1/2'} | Passed |
| fixture 4 | {'decision': [[], False, [], [], 'missing'], 'request': '/requests/1/3'} | {'decision': [[], False, [], [], 'missing'], 'request': '/requests/1/3'} | Passed |
| fixture 5 | {'decision': [['/a', '/b'], True, ['/a', '/b'], ['/a', '/b'], 'present'], 'request': '/requests/1/4'} | {'decision': [['/a', '/b'], True, ['/a', '/b'], ['/a', '/b'], 'present'], 'request': '/requests/1/4'} | Passed |
| fixture 6 | {'decision': [[], False, [], [], 'missing'], 'request': '/requests/1/5'} | {'decision': [[], False, [], [], 'missing'], 'request': '/requests/1/5'} | Passed |
SHA-256 / 1eaeb7ff007000e5aeef3a6be05b0b42cc1dd54fd647a89b3d9aeb368a85668e
Verification & scope
Stipulated offline redirect policy, not a complete HTTP, browser, URL, cache, or security implementation. Numbered variants vary request correlation identity. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.
Observations recorded using Python 3.12.14 at 2026-09-29T14:41:28.830267+00:00.
Case digest / 5b2e96da1c4bedb687357eb83ca18a750dacaac0a027f42b20f70ec097ff0e0c