If you are not sure if the website you would like to visit is secure, you can verify it here. Enter the website address of the page and see parts of its content and the thumbnail images on this site. None (if any) dangerous scripts on the referenced page will be executed. Additionally, if the selected site contains subpages, you can verify it (review) in batches containing 5 pages.
favicon.ico: github.com/stleary/JSON-java/pull/1098/files - JSONPointer: reject array inde.

site address: github.com/stleary/JSON-java/pull/1098/files redirected to: github.com/stleary/JSON-java/pull/1098/files

site title: JSONPointer: reject array index tokens that RFC 6901 does not allow by simpleqt · Pull Request #1098 · stleary/JSON-java · GitHub

Our opinion (on Friday 04 December 2026 4:49:16 UTC):

GREEN status (no comments) - no comments

Meta tags:
description=JSONPointer.readByIndexToken (src/main/java/org/json/JSONPointer.java:226) resolved an array element with Integer.parseInt(indexToken). RFC 6901 section 4 restricts an array index much more narrowly: array-index = %x30 / ( %x31-39 *(%x30-39) ) i.e. 0 , or a digit string whose first digit is 1-9. Integer.parseInt is more permissive than that grammar, so tokens that are not array indexes were accepted whenever Java could read them as a number. Reproducer JSONArray array = new JSONArray( [10,20,30,40,50,60] ); array.query( /0 ); // 10 array.query( /01 ); // 20 - returns a different element instead of failing array.query( /00 ); // 10 array.query( /+1 ); // 20 array.optQuery( /01 ); // 20 /01 does not address the element at index 1 — it does not address any element, since the token is not an array index. Returning 20 hides a bug in the caller s pointer: /0 and /01 name different tokens yet resolve to the same value, and /00//01 silently select element 0/1. +1 is not matched by the grammar either (it is not even a digit string), and a token longer than Integer.MAX_VALUE reported 2147483648 is not an array index for what is really an out-of-range index. Fix Added toArrayIndex(), which parses the token only when it matches the array-index production, and used it in readByIndexToken(). Parsing moved out of the try block whose catch (NumberFormatException) was what made Integer.parseInt the de-facto grammar in the first place; the out of range check and its message are unchanged. /0, /1, ... behave exactly as before. Out of range indexes keep their existing message (index 6 is out of bounds - the array has 6 elements). Tokens that are not array indexes raise JSONPointerException (01 is not an array index), which is what JSONArrayTest/JSONPointerTest already expect for non-index tokens in an array (a is not an array index). Divergence with a readable reference: Jackson s JsonPointer._parseIndex (jackson-core 2.18.2) rejects 01, 00, +1, -1, 1.0, -0, an Arabic-Indic 1 and 0000000000000000001, and accepts 0 and 1. After this change json-java agrees on every one of those tokens. Member names of a JSONObject are not array indexes and are untouched: /01 still addresses the member named 01 (the library has no equivalent of #-escaping a numeric key for arrays). Testing New regression test JSONPointerTest.arrayIndexTokenMustMatchRfc6901Grammar covers the accepted indexes, the rejected spellings, and the optQuery result. RED on the base commit, with the new test in place but JSONPointer.java reverted: Tests run: 43, Failures: 1, Errors: 0 JSONPointerTest.arrayIndexTokenMustMatchRfc6901Grammar:325 Expected JSONPointerException for array index token 01 , got 20 GREEN after the change: mvn test → Tests run: 840, Failures: 0, Errors: 0, Skipped: 6, BUILD SUCCESS (JDK 17 locally, same version CI uses for build-17). No existing test asserted the old acceptance of 01 / 00 ; the full suite is unaffected.;

Headings (most frequently used words):

uh, oh, navigation, jsonpointer, reject, array, index, tokens, that, rfc, 6901, does, not, allow, 1098, footer, diff, view, menu, repository, there, are, no, files, selected, for, viewing, filter, by, extension, sonarqubecloud, sonarcloud, code, analysis,

Text of the page (most frequently used words):
index (33), array (28), the (19), file (19), java (19), not (17), and (17), indextoken (17), github (16), code (16), for (16), this (15), that (14), jsonpointerexception (14), applied (11), new (11), line (10), reload (9), token (9), org (9), json (9), jsonpointer (9), cannot (8), all (8), string (8), show (8), throw (8), currentarr (8), you (7), suggestion (7), suggestions (7), while (7), loading (7), jsonarray (7), does (7), sign (7), changes (6), error (6), section (6), rfc (6), 6901 (6), diff (6), hidden (6), characters (6), unicode (6), open (6), src (6), format (6), length (6), security (5), please (5), commit (5), there (5), was (5), query (5), with (5), tokens (5), number (5), view (5), first (5), your (5), can (4), pull (4), comments (4), page (4), expand (4), catch (4), value (4), try (4), test (4), see (4), rfc6901 (4), x30 (4), bidirectional (4), learn (4), more (4), about (4), return (4), integer (4), position (4), int (4), 1098 (4), main (4), throws (4), out (4), files (4), simpleqt (4), reject (4), allow (4), support (4), copilot (4), community (3), navigation (3), check (3), request (3), from (3), has (3), change (3), add (3), batch (3), one (3), closed (3), retry (3), expected (3), null (3), which (3), failed (3), contains (3), object (3), https (3), are (3), than (3), what (3), review (3), junit (3), jsonpointertest (3), charat (3), issues (3), bounds (3), current (3), hide (3), whitespace (3), filter (3), commits (3), stleary (3), account (3), quality (3), another (3), tab (3), window (3), refresh (3), session (3), developers (3), changelog (3), customer (3), enterprise (3), grade (3), features (3), build (3), contact (2), status (2), privacy (2), terms (2), footer (2), 2026 (2), merge (2), must (2), valid (2), single (2), viewing (2), toggle (2), annotations (2), down (2), asserttrue (2), optquery (2), getmessage (2), message (2), got (2), fail (2), assertequals (2), public (2), void (2), href (2), tools (2), ietf (2), html (2), instead (2), different (2), element (2), into (2), start (2), zero (2), x31 (2), such (2), restricts (2), digit (2), 306 (2), original (2), text (2), may (2), interpreted (2), compiled (2), differently (2), appears (2), below (2), editor (2), reveals (2), desktop (2), delete (2), edit (2), additions (2), deletions (2), parseint (2), reading (2), jsonexception (2), get (2), sonarcloud (2), project (2), aagngq_8o8gen74zqnw1 (2), analysis (2), private (2), static (2), toarrayindex (2), ordinal (2), grammar (2), its (2), valueof (2), elements (2), 224 (2), selected (2), apply (2), split (2), unified (2), load (2), jump (2), extension (2), tree (2), issue (2), insights (2), projects (2), actions (2), repository (2), signed (2), universe (2), training (2), integrations (2), stories (2), center (2), documentation (2), business (2), fixes (2), products (2), secret (2), perform, action, time, share, personal, information, manage, cookies, docs, inc, right, now, back, later, queued, multi, pending, reviews, been, marked, resolved, outdated, existing, order, create, applying, deleted, lines, supported, only, per, subset, invalid, because, were, made, notes, oops, something, went, wrong, coverage, jsonobject, same, rule, applies, reports, 0000000000000000001, arrayindextokenmustmatchrfc6901grammar, them, silently, resolving, therefore, indexes, navigating, tokenlistiscopiedinconstructor, numberformatexception, stleary_json, pullrequest, define, constant, duplicating, literal, times, sonarqubecloud, run, annotation, failure, 255, char, denotes, param, form, they, read, asked, rejected, spellings, accepts, but, converts, readbyindextoken, thrown, conversations, clear, filters, viewed, type, nbsp, nov, 33e9634, select, changed, checks, conversation, wants, fix, master, already, clicking, agree, our, occasionally, send, related, emails, statement, service, free, maintainers, have, question, items, wiki, requests, dismiss, alert, switched, accounts, appearance, settings, search, pricing, event, talks, workshops, next, partners, company, forum, events, webinars, blog, resource, connect, resources, premium, advanced, ons, trust, why, evaluate, industries, government, manufacturing, financial, services, healthcare, industry, nonprofits, startups, small, medium, teams, enterprises, stage, businesses, source, latest, improvements, across, place, developer, articles, sponsors, trending, repos, explore, customize, certifications, scanning, leak, prevention, protection, vulnerability, detection, remediation, secure, cloud, development, environments, codespaces, enforcement, automation, ship, coding, agent, tasks, automated, work, hosting, collaboration, platform, menu, skip, content,
Thumbnail images (randomly selected): * Images may be subject to copyright.GREEN status (no comments)

Verified site has: 61 subpage(s). Do you want to verify them? Verify pages:

1-5 6-10 11-15 16-20 21-25 26-30 31-35 36-40 41-45 46-50
51-55 56-60 61-61


Top 50 hastags from of all verified websites.

Supplementary Information (add-on for SEO geeks)*- See more on header.verify-www.com

Header

HTTP/1.1 301 Moved Permanently
Content-Length 0
Location htt????/github.com/stleary/JSON-java/pull/1098/files
connection close
HTTP/2 200
date Fri, 04 Dec 2026 04:49:15 GMT
content-type text/html; charset=utf-8
vary X-PJAX, X-PJAX-Container, Turbo-Visit, Turbo-Frame, X-Requested-With, X-GitHub-Client-Version, Sec-Fetch-Site,Accept-Encoding, Accept, X-Requested-With
cache-control no-cache
etag W/ 1dedaf38d1fd52ca4c7ca208d017a137
strict-transport-security max-age=31536000; includeSubdomains; preload
x-frame-options deny
x-content-type-options nosniff
x-xss-protection 0
referrer-policy no-referrer-when-downgrade
content-security-policy default-src none ; base-uri self ; child-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/; connect-src self uploads.github.com www.githubstatus.com collector.github.com raw.githubusercontent.com api.github.com github-cloud.s3.amazonaws.com github-production-repository-file-5c1aeb.s3.amazonaws.com github-production-upload-manifest-file-7fdce7.s3.amazonaws.com github-production-user-asset-6210df.s3.amazonaws.com *.rel.tunnels.api.visualstudio.com wss://*.rel.tunnels.api.visualstudio.com github.githubassets.com objects-origin.githubusercontent.com copilot-proxy.githubusercontent.com proxy.individual.githubcopilot.com proxy.business.githubcopilot.com proxy.enterprise.githubcopilot.com *.actions.githubusercontent.com wss://*.actions.githubusercontent.com productionresultssa0.blob.core.windows.net productionresultssa1.blob.core.windows.net productionresultssa2.blob.core.windows.net productionresultssa3.blob.core.windows.net productionresultssa4.blob.core.windows.net productionresultssa5.blob.core.windows.net productionresultssa6.blob.core.windows.net productionresultssa7.blob.core.windows.net productionresultssa8.blob.core.windows.net productionresultssa9.blob.core.windows.net productionresultssa10.blob.core.windows.net productionresultssa11.blob.core.windows.net productionresultssa12.blob.core.windows.net productionresultssa13.blob.core.windows.net productionresultssa14.blob.core.windows.net productionresultssa15.blob.core.windows.net productionresultssa16.blob.core.windows.net productionresultssa17.blob.core.windows.net productionresultssa18.blob.core.windows.net productionresultssa19.blob.core.windows.net productionresultssa30.blob.core.windows.net productionresultssa31.blob.core.windows.net productionresultssa32.blob.core.windows.net github-production-repository-image-32fea6.s3.amazonaws.com github-production-release-asset-2e65be.s3.amazonaws.com insights.github.com wss://alive.github.com wss://alive-staging.github.com api.githubcopilot.com api.individual.githubcopilot.com api.business.githubcopilot.com api.enterprise.githubcopilot.com wss://*.wps.githubcopilot.com wss://production-copilot-host.webpubsub.azure.com wss://production-copilot-host-centralus.webpubsub.azure.com wss://production-copilot-host-centralus-02.webpubsub.azure.com wss://production-copilot-host-westus.webpubsub.azure.com wss://production-copilot-host-westus3.webpubsub.azure.com wss://production-copilot-host-eastasia.webpubsub.azure.com wss://production-copilot-host-austriaeast.webpubsub.azure.com api.github.com/cmc_internal/api/; font-src github.githubassets.com; form-action self github.com gist.github.com copilot-workspace.githubnext.com objects-origin.githubusercontent.com; frame-ancestors none ; frame-src viewscreen.githubusercontent.com notebooks.githubusercontent.com; img-src self data: blob: github.githubassets.com media.githubusercontent.com camo.githubusercontent.com identicons.github.com avatars.githubusercontent.com private-avatars.githubusercontent.com github-cloud.s3.amazonaws.com objects.githubusercontent.com release-assets.githubusercontent.com secured-user-images.githubusercontent.com user-images.githubusercontent.com private-user-images.githubusercontent.com opengraph.githubassets.com repository-images.githubusercontent.com marketplace-screenshots.githubusercontent.com copilotprodattachments.blob.core.windows.net/github-production-copilot-attachments/ github-production-user-asset-6210df.s3.amazonaws.com customer-stories-feed.github.com spotlights-feed.github.com explore-feed.github.com *.googleusercontent.com objects-origin.githubusercontent.com *.githubusercontent.com; manifest-src self ; media-src github.com user-images.githubusercontent.com secured-user-images.githubusercontent.com private-user-images.githubusercontent.com github-production-user-asset-6210df.s3.amazonaws.com gist.github.com github.githubassets.com; script-src github.githubassets.com sha256-6nkh0w49y4npXaU0CPIq0z+XDtPnpaDFECgj6Y9vmx4= ; style-src unsafe-inline github.githubassets.com; upgrade-insecure-requests; worker-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/
server github.com
content-encoding gzip
accept-ranges bytes
set-cookie _gh_sess=PHpsR5%2Bmpl%2BNBHUKqB4hWVoMX2xiEKCsSeSKbbF9rG%2BPr4N9KzbDNmuwXpZGmUkpjUDb2BK5EPvAC1HT2ujkz4bfcGR%2FUJ4B%2FBr1%2BehucVdj%2BPT5j%2BWb9UtuJRyHFudFbkOsiHaCC%2BSq5eXd971yzOXCCK62lITBdHUxSr3e%2BQyQyvvKAHjApN8%2Bzf8I%2FB6uH24psRFfQchtxtTcRcGxjk%2BUi5HUA3A6Q%2BxNwenpHK1yzX2FaXsTmFwy4ij%2Fplm5n1Y7ZstEh6rwzAcRwHaZ3A%3D%3D--7XpeT%2BNUhAx41v49--M1VyMzLsqV7IH5T5ROgtlg%3D%3D; path=/; HttpOnly; secure; SameSite=Lax
set-cookie _octo=GH1.1.1998983574.1796359755; expires=Sat, 04 Dec 2027 04:49:15 GMT; domain=.github.com; path=/; secure; SameSite=Lax
set-cookie logged_in=no; expires=Sat, 04 Dec 2027 04:49:15 GMT; domain=.github.com; path=/; HttpOnly; secure; SameSite=Lax
x-github-request-id 9EDC:224846:268C0CF:3C34577:6B12464B
x-github-edge-region fra

Meta Tags

title="JSONPointer: reject array index tokens that RFC 6901 does not allow by simpleqt · Pull Request #1098 · stleary/JSON-java · GitHub"
charset="utf-8"
name="react-profiling" content="0" data-turbo-transient="true"
name="react-import-map" content="react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322" data-turbo-track="reload"
name="route-pattern" content="/:user_id/:repository/pull/:id/files(.:format)" data-turbo-transient
name="route-controller" content="pull_requests" data-turbo-transient
name="route-action" content="files" data-turbo-transient
name="fetch-nonce" content="v2:148e1bc5-30bb-d885-e6a4-79e75f175c97"
name="current-catalog-service-hash" content="ae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b"
name="request-id" content="9EDC:224846:268C0CF:3C34577:6B12464B" data-pjax-transient="true"
name="html-safe-nonce" content="106d2b478ebacf315638f81707e0ef5503d788222b50bffb8a19c3e86ffdfc40" data-pjax-transient="true"
name="visitor-payload" content="eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5RURDOjIyNDg0NjoyNjhDMENGOjNDMzQ1Nzc6NkIxMjQ2NEIiLCJ2aXNpdG9yX2lkIjoiODU4NTU2OTA3NzM2NzU1NTY1OSIsInJlZ2lvbl9lZGdlIjoiZnJhIiwicmVnaW9uX3JlbmRlciI6ImZyYSJ9" data-pjax-transient="true"
name="visitor-hmac" content="a3e9587d1fcb72f25f67ede04389756e80eaaf6df40d8b955df5886217af53ab" data-pjax-transient="true"
name="hovercard-subject-tag" content="pull_request:5158286081" data-turbo-transient
name="github-keyboard-shortcuts" content="repository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot" data-turbo-transient="true"
name="selected-link" value="repo_pulls" data-turbo-transient
name="google-site-verification" content="Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I"
name="octolytics-url" content="htt????/collector.github.com/github/collect"
name="analytics-location" content="/<user-name>/<repo-name>/pull_requests/show/files" data-turbo-transient="true"
name="user-login" content=""
name="viewport" content="width=device-width"
name="description" content="JSONPointer.readByIndexToken (src/main/java/org/json/JSONPointer.java:226) resolved an array element with Integer.parseInt(indexToken). RFC 6901 section 4 restricts an array index much more narrowly: array-index = %x30 / ( %x31-39 *(%x30-39) ) i.e. "0", or a digit string whose first digit is 1-9. Integer.parseInt is more permissive than that grammar, so tokens that are not array indexes were accepted whenever Java could read them as a number. Reproducer JSONArray array = new JSONArray("[10,20,30,40,50,60]"); array.query("/0"); // 10 array.query("/01"); // 20 <- returns a different element instead of failing array.query("/00"); // 10 array.query("/+1"); // 20 array.optQuery("/01"); // 20 /01 does not address the element at index 1 — it does not address any element, since the token is not an array index. Returning 20 hides a bug in the caller's pointer: /0 and /01 name different tokens yet resolve to the same value, and /00//01 silently select element 0/1. +1 is not matched by the grammar either (it is not even a digit string), and a token longer than Integer.MAX_VALUE reported 2147483648 is not an array index for what is really an out-of-range index. Fix Added toArrayIndex(), which parses the token only when it matches the array-index production, and used it in readByIndexToken(). Parsing moved out of the try block whose catch (NumberFormatException) was what made Integer.parseInt the de-facto grammar in the first place; the out of range check and its message are unchanged. /0, /1, ... behave exactly as before. Out of range indexes keep their existing message (index 6 is out of bounds - the array has 6 elements). Tokens that are not array indexes raise JSONPointerException (01 is not an array index), which is what JSONArrayTest/JSONPointerTest already expect for non-index tokens in an array (a is not an array index). Divergence with a readable reference: Jackson's JsonPointer._parseIndex (jackson-core 2.18.2) rejects 01, 00, +1, -1, 1.0, -0, an Arabic-Indic 1 and 0000000000000000001, and accepts 0 and 1. After this change json-java agrees on every one of those tokens. Member names of a JSONObject are not array indexes and are untouched: /01 still addresses the member named "01" (the library has no equivalent of #-escaping a numeric key for arrays). Testing New regression test JSONPointerTest.arrayIndexTokenMustMatchRfc6901Grammar covers the accepted indexes, the rejected spellings, and the optQuery result. RED on the base commit, with the new test in place but JSONPointer.java reverted: Tests run: 43, Failures: 1, Errors: 0 JSONPointerTest.arrayIndexTokenMustMatchRfc6901Grammar:325 Expected JSONPointerException for array index token '01', got 20 GREEN after the change: mvn test → Tests run: 840, Failures: 0, Errors: 0, Skipped: 6, BUILD SUCCESS (JDK 17 locally, same version CI uses for build-17). No existing...
property="fb:app_id" content="1401488693436528"
name="apple-itunes-app" content="app-id=1477376905, app-argument=htt????/github.com/stleary/JSON-java/pull/1098/files"
name="twitter:image" content="htt????/avatars.githubusercontent.com/u/89645338?s=400&v=4"
name="twitter:site" content="@github"
name="twitter:card" content="summary_large_image"
name="twitter:title" content="JSONPointer: reject array index tokens that RFC 6901 does not allow by simpleqt · Pull Request #1098 · stleary/JSON-java"
name="twitter:description" content="JSONPointer.readByIndexToken (src/main/java/org/json/JSONPointer.java:226) resolved an array element with Integer.parseInt(indexToken). RFC 6901 section 4 restricts an array index much more narrowl..."
property="og:image" content="htt????/avatars.githubusercontent.com/u/89645338?s=400&v=4"
property="og:image:alt" content="JSONPointer.readByIndexToken (src/main/java/org/json/JSONPointer.java:226) resolved an array element with Integer.parseInt(indexToken). RFC 6901 section 4 restricts an array index much more narrowl..."
property="og:site_name" content="GitHub"
property="og:type" content="object"
property="og:title" content="JSONPointer: reject array index tokens that RFC 6901 does not allow by simpleqt · Pull Request #1098 · stleary/JSON-java"
property="og:url" content="htt????/github.com/stleary/JSON-java/pull/1098"
property="og:description" content="JSONPointer.readByIndexToken (src/main/java/org/json/JSONPointer.java:226) resolved an array element with Integer.parseInt(indexToken). RFC 6901 section 4 restricts an array index much more narrowl..."
name="hostname" content="github.com"
name="expected-hostname" content="github.com"
http-equiv="x-pjax-version" content="e789e280037bede4b63bc3e5f7ed28c9f6d54281e50a045e6ad7db2a7f5384d7" data-turbo-track="reload"
http-equiv="x-pjax-csp-version" content="adddfd507de4c4b0b130ff1dbf3c31681ba97e7a45dc69da056946fc5370dfd4" data-turbo-track="reload"
http-equiv="x-pjax-css-version" content="de9d42c9851f7fc17e362ce733048fdc5a047e3bd51005595de23641df84a882" data-turbo-track="reload"
http-equiv="x-pjax-js-version" content="6581a30ca7b80d468b61a0b7b256629bb1df872dbe04c8458bb63c463a388d3e" data-turbo-track="reload"
name="turbo-cache-control" content="no-preview" data-turbo-transient=""
name="diff-view" content="unified" data-turbo-transient
name="go-import" content="github.com/stleary/JSON-java git htt????/github.com/stleary/JSON-java.git"
name="octolytics-dimension-user_id" content="5107558"
name="octolytics-dimension-user_login" content="stleary"
name="octolytics-dimension-repository_id" content="1187853"
name="octolytics-dimension-repository_nwo" content="stleary/JSON-java"
name="octolytics-dimension-repository_public" content="true"
name="octolytics-dimension-repository_is_fork" content="false"
name="octolytics-dimension-repository_network_root_id" content="1187853"
name="octolytics-dimension-repository_network_root_nwo" content="stleary/JSON-java"
name="robots" content="noindex, nofollow"
name="turbo-body-classes" content="logged-out env-production page-responsive full-width"
name="disable-turbo" content="true"
name="browser-stats-url" content="htt????/api.github.com/_private/browser/stats"
name="browser-errors-url" content="htt????/api.github.com/_private/browser/errors"
name="release" content="2370775270b19e77c6de75a6bf49834a4fb14dd9" data-turbo-track="reload"
name="ui-target" content="full"
name="theme-color" content="#1e2327"
name="color-scheme" content="light dark"

Load Info

page size56739
load time (s)1.047799
redirect count1
speed download54191
server IP 140.82.121.3
* all occurrences of the string "http://" have been changed to "htt???/"