Releases

Every tagged release of the projects, newest first. RSS

November 2026

coldbox-graphql 0.2.0

Code-first schemas and support for Adobe ColdFusion.

New

  • Code-first schemas. modelPaths and servicePaths build the schema from annotated CFCs:

    • @graphqlType, @graphqlInput and @graphqlEnum classes;
    • @graphqlQuery and @graphqlMutation service functions;
    • @graphqlCrud, which adds the CRUD shapes.

    The annotations can be doc-comment tags or attributes, and the generated schema can be used alongside hand-written .graphqls files or instead of them.

  • Authorization. @graphqlRequires on properties, resolver methods and service functions, checked by settings.authorizer.

  • Batch loaders. settings.loaders, with nothing cached between requests.

Full notes
  • Interfaces and unions. Resolved through {Type}Resolver.resolveType, then __typename, then the class name.
  • Scalars. DateTime and Long are built in; settings.scalars adds your own as closures.
  • Errors. Errors follow the GraphQL spec's shape, with onError and maskErrors.
  • Limits. maxQueryDepth and maxQueryComplexity.
  • API. execute() and handle() return plain structs.
  • Instances. instanceFactory builds services, resolvers and input beans yourself.

Engines

  • Tested on Lucee 5.4.8.2 and Adobe ColdFusion 2023 (update 26): 138 specs pass on both.
  • The module now runs on ACF, which it did not before.
  • BoxLang apps should use bx-graphql.

Behaviour changes

  • The HTTP endpoint answers 400 when variables isn't an object, and leaves errors out when there are none.
  • resolverBasePackage and schemaPaths are optional when modelPaths or servicePaths is set.
  • A custom scalar that can't serialize a resolver's value fails the whole request, on both engines.

GitHub ↗ About coldbox-graphql

boxlang-ssg 1.1.1

Patch release: tag pages for tags that come from pagination data entries and for sites with a taxonomies document type, and reserved document type names now fail the build with a clear message. See the notes below.

install-bx-module boxlang-ssg bx-yaml bx-markdown bx-jsoup

Fixed

  • A site with a document type named taxonomies and no taxonomies configured now also gets a tag page for a tag carried only by pages that pagination generates.
  • Tags and taxonomy terms that come from pagination data entries (the struct values merged into each page with size: 1) now get their page: when the final terms differ from those pagination was expanded against, the paginated templates are expanded once more. If pages from that second expansion add yet more terms, the build prints a warning naming the template and the terms without a page.
  • A document whose type is all, tags, byTag or global (in any case) fails the build naming the document, instead of corrupting that collection.
Full notes

A site with a document of type all, tags, byTag or global now fails the build; it previously built with that collection corrupted. Give the document another type.

GitHub ↗ About boxlang-ssg

boxlang-ssg 1.1.0

Adds base URL support, permalink patterns, folder defaults, YAML/CSV data, taxonomies, excerpts, previous/next links, a new command, build --watch and live reload in serve. Sites built with 1.0.0 produce the same output unless they opt in; see Changed and Fixed below.

install-bx-module boxlang-ssg bx-yaml bx-markdown bx-jsoup

Added

  • baseUrl config key: a full URL (https://user.github.io/repo/) or a path prefix (/repo). prc.permalink, pagination hrefs and collection permalinks include the path prefix; prc.outFile does not. New prc.absoluteUrl (a front matter absoluteUrl still wins), derived config.pathPrefix and config.siteUrl (a site's own keys of those names are kept as written), and the template helpers relUrl() and absUrl(), which return an argument with a scheme, or starting with // or #, unchanged (a function of the same name in applicationHelper.bxm wins). A baseUrl starting with // is rejected. serve ignores baseUrl and previews at the root.
  • Templates can read the loaded configuration as config, including custom keys from ssg-config.json.
  • Folder defaults: _defaults.yml, _defaults.yaml or _defaults.json supplies front matter for every document in its folder and below.
  • _data/ also loads .yml, .yaml and .csv files. Two of these files for the same key fail the build; beside a .json file of the same key, one is skipped with a warning.
Full notes
  • permalinks config key: a URL pattern per document type, with the tokens :year, :month, :day, :slug, :name, :title and :dir. An explicit permalink still wins, and a pattern does not apply to index documents or the root 404 document.
  • taxonomies config key: group documents by other front matter keys in collections.taxonomies.<name>.terms and .byTerm. A site with a document type named taxonomies keeps collections.taxonomies as that type's collection until it configures taxonomies; with taxonomies configured, such a document fails the build.
  • prc.excerpt (front matter excerpt, the content before <!--more-->, or the first paragraph of a Markdown document) and prc.previous / prc.next within each type collection.
  • new <title> command with --type, --dir and --draft.
  • build --watch rebuilds whenever the source changes. Changing outputDir while build --watch or serve runs triggers one rebuild, not a rebuild loop.
  • serve reloads open pages in the browser after each rebuild; --no-reload turns it off.
  • The starter has an Atom feed (/feed.xml) and a sitemap (/sitemap.xml), links the feed from its layout, uses relUrl() for its own links so it works under a path prefix, shows excerpts on the home page and previous/next links on posts. Its site title, description and author moved from the layout's front matter to site in ssg-config.json, read as config.site.*.

Changed

  • A file named YYYY-MM-DD-name.md without date or publishDate takes its date from the file name; in 1.0.0 it fell back to the file's modified time. So a post (type: post) whose file name carries a future date and that has no date in front matter is now future-dated, and left out of the build unless --drafts; 1.0.0 published it. A date in a file name that is impossible or unparsable (0000-01-01-, 2026-13-01-) is ignored without a warning.
  • .yml, .yaml and .csv files in _data/ are now loaded into collections.global (1.0.0 ignored them), and a _defaults.yml, _defaults.yaml or _defaults.json file now applies to its folder.
  • Data file keys: .json files load exactly as in 1.0.0, so two .json files with the same key (x.json, x.backup.json) still build and the later one wins. A .yml, .yaml or .csv file with the same key as a .json file is skipped, so the output is unchanged, and the build prints a warning naming both files. Two .yml, .yaml or .csv files with the same key fail the build naming both.
  • Existing custom keys named baseUrl, permalinks or taxonomies in ssg-config.json are now validated and fail the build if they have the wrong shape. Custom siteUrl and pathPrefix keys are kept as written; config.siteUrl and config.pathPrefix show the values derived from baseUrl only when the file does not define them. __ssg is reserved for the generator.
  • Render errors name the file that failed (the view or layout, not only the page) and end with (line N) when BoxLang reports a line. An error in a view or layout says which page was being rendered (<file>: while rendering <page>: <message>) and is reported once per build instead of once per page.

Fixed

  • A tag carried only by pages that pagination generates appeared in collections.tags but got no tag page; pagination over collections.tags now covers it. Tags that come only from the pagination data itself may still be missed.

GitHub ↗ About boxlang-ssg

boxlang-ssg 1.0.0

First release as an installable BoxLang module.

install-bx-module boxlang-ssg bx-yaml bx-markdown bx-jsoup
boxlang module:ssg init my-site
  • Output paths changed to folder-style URLs: posts/x.html is now posts/x/index.html (URL /posts/x/), so sites work on any static host. router.bxs was removed.
  • boxlang-ssg is now a BoxLang module, installed once and run from any site folder with boxlang module:ssg <command>. New commands: init, serve, list, clean; new flags: --source, --verbose, --drafts, --port. Exit codes: 0 success, 1 usage error, 2 build failure.
  • setup.bx and requirements.txt were removed. bx-yaml, bx-markdown and bx-jsoup are declared as dependencies in box.json with caret ranges. install-bx-module does not install declared dependencies, so the install command names them; box install boxlang-ssg (CommandBox) does install them. build and serve check for the three modules at startup and print the install command if one is missing.
Full notes

Fixed

  • Builds failed on BoxLang 1.19 because templates were included by absolute path; site templates are now included through an application mapping.
  • Exceptions are no longer swallowed: a page that fails to render is not written, every failure is reported as file: message, and the build exits 2. The error(), print.greyline(), dump() and abort calls are gone.
  • Pagination wrote page 1 of permalink: /jokes/page/{{page}}/index.html to /jokes/page/index.html/index.html; every page now substitutes its number, and paginationInfo.href values point at files that exist.
  • Paginated pages respect excludeFromCollections in type collections as well as all, and type keys are lower-cased consistently.
  • Discovery matches .md and .bxm by extension rather than by substring, and always skips _includes/, _data/, the output folder, dot-folders at any depth, boxlang_modules/ and node_modules/. Only the root README.md is skipped by default.
  • Front matter without a closing marker, or .md front matter that is not valid YAML, fails the build naming the file; an empty tags: no longer throws.
  • Posts sort newest first by date, then publishDate, then file modified time, without throwing when dates are missing. Future-dated posts are treated as drafts unless --drafts.
  • Tag permalinks use the slugified tag, and the starter links to the URL the tag page is written to.
  • The starter layout uses the page's title and description, falling back to the site values.
  • ssg-config.json is merged over defaults and validated; outputDir must be inside the site root and not the site root itself.
  • bx-markdown is no longer pinned to an exact version.
  • pagination.data resolves against collections only, and a path that does not exist fails the build instead of being created silently.
  • An explicit permalink on a type: post document was ignored when choosing the output file; an explicit permalink now wins for every type.
  • collections.tags and collections.byTag are built in one place from every document with tags that is not excluded from collections.
  • An empty front matter value such as title: left the key null on BoxLang without bx-compat-cfml; it now falls back to the default.
  • The starter's post date and stylesheet cache-buster used CFML date masks (mmm, yyyy-mm-dd), which fail or print minutes on BoxLang without bx-compat-cfml; they now use MMM and yyyy-MM-dd.

Changed

  • collections.tags is now sorted case-insensitively.
  • Generated pagination pages now take part in type and tag collections and honour excludeFromCollections.
  • A paginated template with no explicit permalink bases its pages on its own resolved permalink; size: 1 without a placeholder writes page/<n>/ instead of overwriting one file.
  • minify and tidyHtml apply to HTML output only (previously minify also touched non-HTML output such as XML feeds).
  • Front matter must start on the first line of the file.
  • In .bxm files a leading comment that is not a YAML mapping is treated as an ordinary comment with a warning.
  • Two documents that resolve to the same output file, a missing passthru entry, invalid config, and front matter/pagination/render errors now fail the build with exit code 2 instead of being skipped silently.
  • Bootstrap JS, jQuery and Popper removed from the starter layout.
  • prc.inFile and prc.outFile are now paths relative to the site root and the output folder (they were absolute paths), and prc.date is always a date object.
  • A passthru entry that is empty, ., an absolute path or contains .. now fails the build; entries must be paths inside the site root.
  • serve uses a web server built into the module and no longer needs boxlang-miniserver. It listens on 127.0.0.1 only, so the site is reachable from your own machine alone, and it answers a missing page with the site's 404.html.

GitHub ↗ About boxlang-ssg

bx-graphql 0.3.0

CRUD from a bean

@graphqlCrud( "WidgetService" ) on a bean generates a field for each of get, list, save and delete that service has: widget( id ), widgets, saveWidget( input ) and deleteWidget( id ). @graphqlCrudNames( "list=people" ) renames them. See CRUD from a bean in the README.

  • Paging — parameters of the service's list() named limit and offset become Int arguments of the list field.
  • Two classes under servicePaths with the name a @graphqlCrud gives fail at construction time.

Safer in front of untrusted clients

  • Query limits — maxQueryDepth and maxQueryComplexity refuse an oversized query before any resolver runs.
  • Introspection toggle — introspection : false refuses __schema and __type.
  • Error masking — maskErrors : true tells clients Internal server error when a resolver throws; a function decides which messages pass. onError still receives the real exception.
Full notes
  • Guards on properties and hand-written resolvers — @graphqlRequires now works on a bean's properties and on methods of {Type}Resolver.bx classes.

Also new

  • operationName — a fourth argument to execute(), for a document holding several operations.
  • handle( body, context ) — runs a GraphQL-over-HTTP request body, as a struct or JSON text; a body that can't be run comes back as an entry in errors.

Changed

  • @graphqlRequires on a bean's class now covers its properties as well as its @graphqlField functions.
  • The app's context travels in graphql-java's GraphQLContext. The context argument is unchanged, but env.getContext() no longer returns it: use the argument, or env.getGraphQlContext().get( "bxgraphql.context" ).

Housekeeping

  • MIT LICENSE file, and a GitHub Actions workflow that runs the specs on every push and pull request.

GitHub ↗ About bx-graphql

bx-graphql 0.2.0

Code-first schema

Annotate the classes you already have instead of (or as well as) writing .graphqls files and resolver classes. See Code-first schema in the README.

  • Types and inputs from beans — modelPaths: classes marked @graphqlType / @graphqlInput, a field per property, doc comments as descriptions. @graphqlId, @graphqlField, @graphqlInputField, @graphqlReadOnly, @graphqlWriteOnly, @graphqlIgnore, @graphqlDeprecated.
  • Queries and mutations from services — servicePaths: public functions marked @graphqlQuery / @graphqlMutation, wired straight to the method. Input arguments arrive as populated beans; context, env and args parameters are injected.
  • Functions as fields — @graphqlField on a bean's function.
  • Enums — @graphqlEnum( "A, B, C" ).
  • Interfaces and unions — written in SDL, joined with @graphqlImplements; the concrete type comes from resolveType(), __typename, or the bean's class.
  • Authorization — @graphqlRequires( "what" ) with an authorizer setting.
  • Batch loading — a loaders setting backed by graphql-java's DataLoader.
Full notes
  • getGeneratedSDL() and printSchema().

Also new

  • Custom scalars — a scalars setting, with DateTime and Long built in.
  • Structured errors — structuredErrors : true gives { message, path, locations, extensions }; onError receives each error with its exception.
  • instanceFactory — build services, resolvers and input beans through your own DI.

Changed

  • A resolver that returns a class instance now has its fields read through getters and public members. They used to come back null, without an error.
  • Resolver args hold the values as graphql-java coerced them, no longer passed through a JSON round trip.
  • schemaPaths and resolverBasePackage are optional once modelPaths or servicePaths is set. Without those, both are required as before.

Schema-first apps need no changes. Developed and tested on BoxLang 1.19.0.

GitHub ↗ About bx-graphql

bx-feeds 0.5.1

  • Breaking: an RSS or Atom item without a guid gets its link as the feed wrote it as its id, not the resolved link. That is what ROME falls back to, so ids match those an app built on ROME has already stored. Only items with a relative link are affected.
  • An RSS 0.9x or 1.0 description that is plain text is escaped; it used to be returned as HTML, so 3 < 4 could lose text. One that holds tags is still HTML, and gets paragraphs where it has blank lines.
  • Plain text (Atom, JSON Feed, Media RSS and the above) becomes a <p> for each run of lines, not lines joined with <br>.
  • dropEmptyItems option: items with no title, link, content or enclosure are left out, and a feed of nothing else throws Feeds.ParseError.

GitHub ↗ About bx-feeds

bx-feeds 0.5.0

  • fallbackUserAgents: a site that refuses the User-Agent with a 401 or 403 is asked again as each fallback, and the one a host accepts is remembered.
  • challenged on the fetch result: the refusal is a bot check (Cloudflare, or a CAPTCHA) that no fetch can pass.
  • A site that answers a feed fetch with 429 is left alone, for its Retry-After or 15 minutes doubling up to four hours. Until then fetches of its feeds return a 429 marked paused without a request. pauseAfter429: false turns this off.
  • retryNotFound: addresses matching a pattern are asked again after a 404.
  • FeedFetcher gains pausedSites(), pausedSeconds(), endPause(), forget() and siteOf().

GitHub ↗ About bx-feeds

  • Flash: event.getFlash() and a flash variable in views, kept in the BoxExpress session.
  • this.prehandler_only / _except, the same for posthandler and aroundhandler, and aroundHandler( event, targetAction, eventArguments, rc, prc ).
  • Routes: get(), post(), put(), patch(), delete(), group(), toView(), toRedirect(), apiResources(), and resources() with a pattern and a handler for nesting.
  • A POST with _method=PUT, PATCH or DELETE in its body is routed as that method. _method no longer appears in rc.
  • Event: paramValue(), getOnly(), getExcept(), populateModel(), isAjax(), getHTTPContent().
Full notes
  • onMissingAction and onInvalidHTTPMethod on a handler.
  • Interceptors: an interceptors setting, event.announce() and mvc.announce().
  • Changed: aroundHandler, onMissingAction and onInvalidHTTPMethod are reserved names and can't be actions.
  • examples/todo uses flash for its messages and this.prehandler_only; examples/starter uses get() and toView().

GitHub ↗ About boxlang-express-mvc

  • this.allowedMethods on a handler limits an action to the listed HTTP methods on every route, the convention route included. A wrong method gets a 405 with an Allow header.
  • Changed: an action is now a public function whose first argument is named event. Other public functions are no longer routable.
  • Changed: relocate() throws BoxExpressMvc.InvalidRelocation for //host and /\host, which a browser reads as another site.
  • Fixed: buildLink() used a param name as a regular expression.
  • examples/todo adds security headers, a rate limit and a cap on the list; its Dockerfile pins the base image by digest. examples/starter defaults to production.
Full notes
  • CI: read-only token, no stored checkout credentials, actions and the CommandBox image pinned; Dependabot keeps the pins current.
  • examples/todo: a todo list with sessions, CSRF protection and a Dockerfile. examples/starter is the former examples/ app.
  • A GitHub Actions workflow runs the specs on every push.
  • examples/todo installs bx-esapi and uses encodeForHTMLAttribute() in attributes. The docs say to install it in every app.

GitHub ↗ About boxlang-express-mvc

boxlang-express 0.2.30

  • An error after the response is sent is logged (models/Router.bx, #8). A handler that threw, or called next( err ), after res.send() had its error dropped: error handlers are skipped because nothing more can be sent, and nothing was printed either. It now writes one line to stdout — Error after the response was sent, GET /path: message — with the request id when requestId is on. The response is unchanged and error handlers are still skipped. A client that disconnects in the middle of a download or an SSE stream now produces this line too.
Full notes
  • Changed behaviour: boxExpressCsrf() mints its token on the first req.csrfToken() call (models/middleware/Csrf.bx, #9). It used to write req.session.csrfToken on every request, so with the session and CSRF middleware mounted app-wide every anonymous request became a stored session and saveUninitialized: false did nothing. A request that never asks for a token now leaves the session alone. An unsafe request whose session has no token gets the same 403 as before, and no token is minted for it. Code that read req.session.csrfToken directly, without calling req.csrfToken(), will find it unset.
  • res.renderToString( view, data ) (models/Response.bx, #10) returns what res.render() would send without sending it: the same app.locals / res.locals / data merge and the same layout rules, including layout: false. render() is now renderToString() plus the send.

GitHub ↗ About boxlang-express

  • First version: boxExpressMvc(), handlers with ( event, rc, prc ) actions, preHandler / postHandler, the route DSL (route, withAction, resources, named routes, the convention route), .bxm views and layouts, and handler wiring from a services struct or a WireBox injector.

GitHub ↗ About boxlang-express-mvc

bx-couchcache 0.1.2

Changed

  • The shared-connection lookup key is hashed, so the password is no longer held in memory as part of it
  • Readme: a Security section (deserialization trust, TLS, prefix overlap, key length, lock limits)

Install with install-bx-module bx-couchcache or box install bx-couchcache.

GitHub ↗ About bx-couchcache

bx-couchcache 0.1.1

Fixed

  • A script that ended with a cache still open printed Exception in thread "dnsjava NIO shutdown hook" ... Class loader [couchcache] is closed. The module now shuts its caches down when it unloads, and stops the SDK's DNS client with the last connection

Install with install-bx-module bx-couchcache or box install bx-couchcache.

GitHub ↗ About bx-couchcache

bx-couchcache 0.1.0

First public release of bx-couchcache, a Couchbase cache provider for BoxLang.

Install with install-bx-module bx-couchcache or box install bx-couchcache. Needs BoxLang 1.18+ and Couchbase Server 7.6+.

Added

  • First iteration of this module: CouchCache cache provider with session storage and bx:lock distributed locking
  • getObjectStore() returns a delegating object store that reports isDistributed() == true, so BoxExpress accepts the cache as durable for sessions
  • Range scans are consistent with the provider's own writes, so getKeys, getSize and clearAll no longer miss a key written just before
  • BoxExpress integration tests: sessions (including over HTTP), rate limiting and cluster mode
  • Two-JVM BoxExpress integration test (sessions, rate limiting, cluster members, key listing and bx:lock across processes)
Full notes
  • Outage and startup-failure tests; the suite also passes on Couchbase Server 7.6.2
  • Testcontainers integration tests for caching, expiry, key prefixes, serialization, sessions and locks

Changed

  • Minimum BoxLang version is 1.18.0; the module is built and tested against BoxLang 1.19.0
  • Caches with the same connection string, credentials and bucket share one Couchbase connection
  • Range scans use the KV timeout instead of the SDK's 75 second default
  • set() only does its insert-or-update lookup when an interceptor listens for those events
  • ./gradlew shadowJar on its own now includes the ServiceLoader registration
  • Pinned the Couchbase Java SDK to 3.13.1

Fixed

  • A cache that failed to start left its Couchbase connection open and retrying in the background
  • A cache pointed at an unreachable host reported a disconnect timeout instead of the connection failure
  • Lock expiry under one second threw InvalidArgumentException. Lock TTLs are now rounded up to whole seconds.

GitHub ↗ About bx-couchcache

boxlang-express 0.2.29

  • boxExpressRateLimit( { handler } ) (models/middleware/RateLimit.bx): handler: ( req, res, next, info ) => ... answers a limited request in place of the JSON message, as in express-rate-limit — so a route that serves HTML can render a page instead of handing a reader a JSON blob. The status and, with standardHeaders on, Retry-After are set before it runs, so res.render( ... ) goes out as a 429. info is { limit, remaining, resetSeconds, key }; resetSeconds is the value sent in Retry-After. It works the same with the in-memory store, cache and a custom store. Without handler the response is unchanged. A handler that isn't a function throws when the middleware is created.
Full notes
  • The session cookie is Secure over HTTPS by default (models/middleware/Session.bx): boxExpressSession()'s secure option now defaults to "auto" instead of false — the cookie gets the Secure flag whenever req.secure is true, so a site behind a TLS-terminating proxy (with "trust proxy" set) no longer sends its session id back over plain HTTP unless told to. Plain-HTTP requests are unchanged, and secure: true / secure: false still force it either way; anything else throws BoxExpress.InvalidOption. An app that is deliberately served over both HTTP and HTTPS and shares one session between them needs secure: false.
  • Changed default: res.cookie() sends SameSite=Lax (models/Response.bx). Until now a cookie got no SameSite attribute unless sameSite was passed, leaving it to each browser's default. A cookie that must be sent on cross-site requests — an embedded widget, a login flow that posts back from another origin — now needs { sameSite: "None", secure: true }. sameSite: false restores the old behaviour (no attribute) and true means "Strict". res.clearCookie() follows the same default. The session cookie was already Lax.
  • Changed default: at most 1000 parameters in a query string or urlencoded body (models/QueryString.bx). The byte limits alone allowed tens of thousands of keys per request. A query string over the limit is answered 400 before any middleware runs; set it with app.set( "parameterLimit", n ). A urlencoded body over it is answered 413; set it with boxExpressUrlencoded( { parameterLimit: n } ). 0 turns either off. A repeated key counts once per appearance, and the request is refused, not truncated.
  • Changed default: boxExpressUpload() takes at most 100 files and 1000 fields (models/middleware/Multipart.bx), with new maxFiles and maxFields options; over either is a 413 and nothing is written to dest. 0 turns a limit off.
  • boxExpressRateLimit( { maxKeys } ) (models/middleware/RateLimit.bx): the in-memory store counts at most maxKeys keys (default 100000) separately. Past that, a key not already being counted goes into one shared bucket until others expire, so a flood of distinct keys can neither grow memory without limit nor get through uncounted. A warning is logged at most once a minute while it's full. 0 removes the cap; cache and store are unaffected.
  • SECURITY.md: how to report a vulnerability privately, which versions get fixes, and what's in scope.
  • models/middleware/Csrf.bx's header comment said the token comparison wasn't constant-time; it has been since 0.2.20. Comment only.

GitHub ↗ About boxlang-express

boxlang-express 0.2.28

  • Breaking: a key repeated in a query string or urlencoded body is now an array (?tag=a&tag=b → { tag: [ "a", "b" ] }), as in Express 5. Before, the last value silently replaced the others, which lost data from multi-select forms and filter UIs. A handler that treats req.query.x or a form field as a string will throw if a client repeats the key — declare the field with boxExpressValidate() or check isArray().

    • Both parsers now share models/QueryString.bx, with the semantics of Node's querystring (Express 5's default "simple" parser). A key that appears once is still a string. Brackets are not parsed: tag[] and user[name] stay literal keys. There is no query parser setting.
    • Keys that differ only in case are one key, because a BoxLang struct's keys are case-insensitive: ?Tag=a&tag=b is { Tag: [ "a", "b" ] }. Express would give two keys.
    • Unchanged: + is a space in both; a malformed % escape is kept as raw text in a query string and answered with 400 in a body.
    • app.inject( { query: { tag: [ "a", "b" ] } } ) already sent both values; the handler now receives both.
    • boxExpressUpload() does the same for a repeated non-file field in a multipart body (models/middleware/Multipart.bx); it also kept only the last value.
    • boxExpressCsrf() ignores a token field sent more than once and falls back to the header, so such a request is rejected as before.
  • boxExpressValidate() and arrays (models/middleware/Validate.bx):

    • type: "array" accepts a single simple value as a one-item array, so ?tag=a and ?tag=a&tag=b both validate. This also applies to JSON bodies: "tags": "a" is now accepted as [ "a" ], where it was a 400.
    • An untyped field with oneOf, pattern, minLength or maxLength now rejects an array or object ("must be a single value"). Those rules were skipped for a non-simple value, so { "role": [ "root" ] } passed a oneOf check — and with repeated keys, ?role=root&role=x would have too.
    • Scalar types already rejected arrays; that's unchanged.
  • ETags for buffered responses (models/Response.bx, models/ConditionalGet.bx): app.set( "etag", "weak" | "strong" | true | false | ( bodyBytes, encoding ) => tag ). Off by default — Express turns weak tags on, but a new header and a SHA-1 pass per response shouldn't arrive with an upgrade. An invalid value throws at app.set(). The weak format is the etag package's (W/"<length in hex>-<27 characters of base64 SHA-1>"). A response is tagged only for GET/HEAD, a 2xx status, a non-empty body and no ETag set by the handler.

  • req.fresh / req.stale (models/Request.bx), with the fresh package's rules as in Express 5: If-None-Match (*, a list, weak comparison) decides when present, otherwise If-Modified-Since against Last-Modified; Cache-Control: no-cache on the request is always stale. They are read like properties and computed on each read.

  • Buffered GET/HEAD responses now answer 304 when the request is fresh, with no body and without Content-Type or Content-Length; res.getBytesWritten() reports 0. This applies with etag off too: a handler that already sets its own ETag or Last-Modified before res.send()/res.json() will start answering matching conditional requests with 304, as Express does. sendFile(), static files and res.sse() are unchanged.

    • sendFile() and static files now send the file in full when the request says Cache-Control: no-cache (a hard reload), matching the rule above; they answered 304 before.
    • The exchange adapters gained removeHeader(). A hand-written exchange adapter needs one.
    • Request.bx is now declared with accessors=true invokeImplicitAccessor=true so req.fresh can be computed when read; req gains getFresh()/getStale() and unused generated setFresh()/setStale() methods.
  • Fix: app.inject() threw "Count cannot be zero" for a URL that is only a query string ("?page=2") (models/BoxExpress.bx).

GitHub ↗ About boxlang-express

  • A test provider for apps' own specs (boxExpressAuthTestProvider(), models/providers/TestProvider.bx). login( app, { identity } ) runs the real routes — state, PKCE, verify(), session regeneration — through app.inject() and hands back the cookies; deny and fail simulate a refusal or a broken provider. Its authorize URL is under .invalid and codes only exist once test code calls approve(), so registering it by mistake doesn't open a login.
Full notes
  • Logout at the issuer for OIDC providers (RP-initiated logout). With postLogoutRedirectUrl, POST /auth/logout destroys the session and then sends the browser to the discovered end_session_endpoint (a 303, or 200 { logoutUrl } for a fetch()). The ID token is kept for id_token_hint only with logoutIdTokenHint: true, so by default the session still holds no provider token at all. req.session.auth.provider now records which provider a login came through.
  • Microsoft (Entra ID) preset (boxExpressAuthMicrosoft()), with tenant (common, organizations, consumers, a tenant id or domain) and allowedTenants. The multi-tenant endpoints' templated issuer is handled by checking each token's iss against its own tid. The email is never reported as verified: Microsoft doesn't verify it.
  • GitLab preset (boxExpressAuthGitLab()), for gitlab.com or a self-managed baseUrl.
  • Account linking: with a link( identity, user, tokens, req ) option, POST /auth/:provider/link lets a signed-in user attach another provider account. POST only (so it sits behind CSRF protection), same callback and checks as a login, refused with link_denied if the signed-in user changed in between. linkRedirect and linkFailureRedirect options.
  • ES256/ES384/ES512 ID tokens (models/Jwt.bx), verified against EC JWKs on the curve the algorithm names, for issuers that sign with ECDSA.
  • Sign in with Apple (boxExpressAuthApple()). Apple's ID tokens are ordinary RS256; what's different is everything around them:
    • The client secret is an ES256 JWT signed with the team's .p8 key (teamId, keyId, privateKey), minted fresh with a five-minute lifetime for every code exchange.
    • Asking for name or email makes Apple return with a cross-site form POST, which a SameSite=Lax session cookie doesn't ride along on. The new POST /auth/:provider/callback answers it with a 303 to the usual GET callback — a top-level navigation, which does carry the cookie — so every state, PKCE and ID-token check runs unchanged. Only code, state and error go into that URL.
    • The user's name, which Apple posts once on first authorization and never in the ID token, is held in memory under a hash of the state until the GET callback collects it. The posted email and id_token are ignored in favour of the signed token from the token endpoint.
    • auth.formPostRoutes() mounts just that POST route ahead of boxExpressCsrf(), which would refuse Apple's tokenless POST.
  • Providers can now override clientSecretValue() (what's sent as client_secret) and receive state in fetchProfile()'s context.
  • Guards on WebSocket upgrades: auth.required() in app.ws( path, handler, { use: [ sessions, auth.required() ] } ) (BoxExpress 0.2.27+) answers an anonymous upgrade with a plain 401, never a login redirect, whatever its Accept header says. Covered by a spec against a real listening server.
  • OIDC subclasses can override discoveryIssuerMatches() and tokenIssuerAllowed() for issuers whose iss isn't a fixed string.

GitHub ↗ About boxlang-express-auth

  • Google sign-in (models/providers/Google.bx, boxExpressAuthGoogle()), built as a preset of a new generic OpenID Connect provider (models/providers/OIDCProvider.bx, boxExpressAuthOIDC()) rather than a Google-only class: Google needs nearly everything OIDC does (discovery, a nonce, ID-token validation), and the tracker's self-hosted Keycloak and Authelia need exactly the same code.
    • The ID token's signature is checked against the issuer's JWKS even though it arrives straight from the token endpoint, where OIDC Core and Google's docs both allow skipping it. It's cheap, and it means a misrouted or intercepted token endpoint can't mint a login.
    • iss, aud/azp, exp/iat and the nonce are all checked; none and HMAC algorithms and RSA keys under 2048 bits are refused. The discovery document must name the configured issuer, or it could point validation at someone else's keys. Plain http is allowed only for loopback issuers, for local Keycloak/Authelia.
    • The JWKS is cached and refetched once for an unknown kid (how a key rotation shows up), throttled by jwksMinRefreshSeconds.
    • Userinfo is read only when the ID token has no email (Authelia's default), must describe the same sub, and can't override signed claims.
    • Google's hostedDomain is enforced against the signed hd claim, not just sent as the hd parameter: Google documents the parameter as a UI hint a user can strip.
    • Only RS256/RS384/RS512 ID tokens for now (models/Jwt.bx), which covers Google, Keycloak and Authelia defaults.
  • Pending logins and identities are keyed by the name a provider is registered under (models/Auth.bx), not the provider's own name. Two generic OIDC providers share a class; keyed by name, they'd have overwritten each other's pending state.
  • GET /auth/:provider builds the authorize URL before storing anything, and a failure there is a provider_error redirect instead of a 500 — an OIDC provider may fetch its discovery document at that point, and an IdP outage shouldn't look like a crash.
  • authorizeParams on every provider passes extra authorize-URL parameters (prompt, login_hint, …). The parameters the flow's security rests on (state, nonce, PKCE, redirect_uri, scope) are refused, so configuration can't quietly weaken it.
  • exchangeCode() also returns idToken when the provider sends one, so verify() can keep it (for RP-initiated logout) — it's still never stored by this module.

GitHub ↗ About boxlang-express-auth

  • First release: third-party login for BoxExpress apps, built for a developer-facing issue tracker that needs "Sign in with GitHub" now and self-hosted OIDC (Keycloak/Authelia) and Google next.
  • Core (models/Auth.bx, boxExpressAuth()): routes() for GET /:provider, GET /:provider/callback and POST /logout; required()/optional() guards. The app supplies verify() to map an identity to its own user, because only the app knows how its users are stored — the module never creates or stores users itself.
Full notes
  • Security choices, each because the naive version is exploitable:
    • state is 32 CSPRNG bytes, single-use (deleted before it's checked, so a failed attempt spends it too), expires after 10 minutes, and is compared in constant time.
    • PKCE S256 on every login, so an intercepted code is useless without the verifier held in the session.
    • The session is regenerated before the user id is written, so a session id planted before login never becomes an authenticated one.
    • returnTo accepts only relative paths and rejects //, /\, any backslash and any control character. Browsers strip tab/CR/LF from URLs, so /<TAB>/evil.com would otherwise pass a prefix check and resolve as //evil.com.
    • Provider tokens go to verify() and nowhere else: not the session, not the logs. Failure redirects carry only a fixed set of codes, never provider-supplied text.
    • Logout is POST-only, so another site can't sign users out with a link, and it works under boxExpressCsrf().
    • A verify()/loadUser() that throws reaches the app's error handler as a 500 instead of being reported as a failed login, so a database outage isn't mistaken for bad credentials.
  • Providers (models/providers/OAuth2Provider.bx, GitHub.bx, boxExpressAuthGitHub()): the base class owns the authorize URL, code exchange, and option checks, so adding a provider is mostly fetchProfile(). GitHub identities use the numeric id (logins can be renamed and re-registered) and take the email from /user/emails, since /user often has none and never says whether it's verified. The provider interface already takes a nonce so OIDC can be added without changing it.
  • Outbound HTTP is injectable (models/HttpClient.bx, httpClient option): specs run the whole flow against a fake that fails on any unexpected URL, so none of them touch GitHub. The default client treats bx:http's synthetic "502 Connection Failure" as an error rather than a response, since it means nothing answered.

GitHub ↗ About boxlang-express-auth

boxlang-express 0.2.27

  • Request helpers (models/Request.bx, new models/Negotiator.bx): the parts of Express's req that a ported handler reaches for first and had to be hand-rolled from req.headers until now.
    • req.accepts() and req.acceptsLanguages() pick from the types or languages you offer by the client's q weights, returning false when none is acceptable. req.is() matches the request's own Content-Type, including wildcards, +json-style suffixes and the urlencoded/multipart shorthands. The rules follow the npm negotiator and type-is packages, minus media-type parameters other than q. req.is() returns false, not null, for a request with no body.
    • req.xhr, and req.subdomains with app.set( "subdomain offset", n ).
    • req.baseUrl (models/Router.bx): the mount path of the router or path-scoped middleware handling the request. A mounted router had no way to learn where it was mounted, so it couldn't build a link to itself without the prefix hard-coded.
    • No req.fresh/req.stale yet — they only mean something once res.send()/res.json() set an ETag, which they don't.
  • Response helpers (models/Response.bx):
    • res.clearCookie(), plus domain and expires options on res.cookie() — without domain a cookie scoped to a parent domain could be neither set nor cleared.
    • res.vary() adds to Vary instead of replacing it. boxExpressCors() now uses it, so its Vary: Origin no longer overwrites a Vary set earlier in the chain. A hand-written fake res passed to the CORS middleware in a unit test needs a vary() method.
    • res.format() dispatches on Accept, sets Content-Type and Vary: Accept, and answers 406 when nothing matches. Pass an ordered struct ([ ... ]): a plain { ... } has no key order to fall back on when the client has no preference.
    • res.get(), res.append(), res.location(), res.links(), res.attachment(), res.set( { ... } ) for several headers at once, and an extension shorthand for res.type( "json" ). res.append() joins values into one comma-separated line (a line each for Set-Cookie) so res.get() still returns the whole value.
  • Timeouts and size limits (models/BoxExpress.bx, models/HttpBridge.bx, new models/RequestWatchdog.bx; see docs/limits.md). Until now the only bounds on a request were the body parsers' own limits and the accept backlog.
    • app.set( "requestTimeoutMs", n ) answers 503 when a handler hasn't started its response in time; req.setTimeout( ms ) changes or removes it for one request. Off by default. The handler's thread is interrupted and sends the 503 itself — the watchdog never writes to the response, because Undertow's exchange isn't safe to write from a second thread while the handler may be using it. The trade-off is that a handler which never blocks isn't stopped. Error-handling middleware doesn't run for a timeout; a handler that catches the interruption can check req.timedOut. A response that has already started (SSE, a file download) is never cut off.
    • app.set( "maxBodySize", bytes ) answers 413 before any handler runs, on Content-Length alone when there is one. Off by default, so upgrading can't start rejecting uploads. This is enforced in BoxExpress rather than with Undertow's MAX_ENTITY_SIZE, which was tried first: it answered an oversized request with a 500, or dropped the connection with no response for a chunked one, and printed a stack trace either way. A chunked body is read into memory up to the cap to measure it.
    • headerTimeoutMs defaults to 60 s. Before, a client that never finished sending its headers was held open indefinitely (measured against 0.2.26: still open after 75 s).
    • maxHeaderSize defaults to 64 KB, down from Undertow's 1 MB; a request over it gets a 400. Raise it if you send unusually large headers.
    • keepAliveTimeoutMs makes the idle keep-alive timeout configurable. Its default, 60 s, is what Undertow already did.
  • Text and raw body parsers (models/middleware/BodyParsers.bx, new bifs/boxExpressText.bx, bifs/boxExpressRaw.bx; see docs/middleware.md):
    • boxExpressText() puts a text/plain body on req.body as a string, decoded with the charset the request names (415 for one the JVM can't decode). boxExpressRaw() puts an application/octet-stream body there as the exact bytes.
    • All four parsers take a type option — the same patterns as req.is(), an array, or a function — so boxExpressJSON( { type: [ "json", "+json" ] } ) parses application/vnd.api+json. With no type, json() and urlencoded() match exactly as before.
    • All four take a verify( req, res, bodyBytes ) option, called with the bytes as received before they're parsed; throwing answers 403. This is what a webhook signature check needs: the signature covers the sender's exact bytes, which re-serializing parsed JSON doesn't reproduce, and before this the only way to see them was to skip the parser and read req.bodyStream() by hand.
    • A parser now skips a request an earlier parser, or boxExpressUpload(), already handled. The body stream can only be read once, so a second parser was reading nothing — harmless while no two parsers could match the same request, but a catch-all type: "*/*" would have replaced a parsed req.body with an empty one.
  • Signed cookies (new models/CookieSigner.bx, models/Request.bx, models/Response.bx): app.set( "cookie secret", secret ), then res.cookie( name, value, { signed: true } ) and req.signedCookies. A cookie that fails verification reads as false and, like every signed cookie, is removed from req.cookies, so a forged value can't be read as a plain one. An array of secrets signs with the first and verifies with all, for rotation. The format is cookie-parser's, byte for byte (checked against Node's own HMAC output), so an Express app with the same secret reads these cookies and vice versa. No j: JSON cookies. Setting a secret changes nothing for an app that doesn't sign: only values starting s: are affected.
  • View layouts and partials (models/Response.bx; see docs/views.md): app.set( "view layout", name ) wraps every res.render() in a layout view, which gets the rendered view as data.body. The view runs first, so it can set a title or anything else on data for the layout to read. layout in the render data (or res.locals) picks another layout for one render, or false for none. partial( view, data ) renders another view inline, with the caller's data plus its own. Until now every view had to include its own header and footer. layout is now a reserved key in render data.
  • Access log (models/HttpBridge.bx, new models/AccessLog.bx; see docs/observability.md): app.set( "log", "access" ) or "json" logs each request when it's answered, with status, duration and bytes sent; a function receives the entry instead. The default (true) is unchanged — a line on arrival — which can't say how a request went, and getting status and duration meant writing logging middleware around res.getStatusCode(). The logged path leaves out the query string. An invalid "log" value now throws at app.set(). The timeout log line no longer prints the query string either.
  • Binary WebSocket sends (models/WebSocketConnection.bx): connection.sendBinary( bytes ), and connection.send() sends a binary frame when handed a byte[]. A connection could receive binary messages (onBinary()) but only ever answer in text.
  • Cron schedules (new models/CronExpression.bx, models/Scheduler.bx; see docs/scheduler.md): app.schedule( "0 2 * * *", callback ) runs a job at clock times. Five fields or six with seconds, ranges, lists, steps, month and weekday names, @daily-style shorthands, and options.timezone. An interval can't say "every night at 2" — the first run lands wherever the process happened to start. Cron parsing was left out of the first scheduler on purpose as a separable feature; this is it. A cron job is driven by a one-shot timer re-armed after each run, since the gap between fire times isn't constant. A malformed expression, or one that can never fire, throws at schedule().
  • Middleware for WebSocket upgrades (models/BoxExpress.bx, new models/adapters/WsUpgradeMiddleware.bx; see docs/websockets.md): app.ws( path, handler, { use: [ ... ] } ) runs ordinary middleware against the upgrade request. The socket opens only if they all call next(); one that responds refuses the upgrade. The handler receives the request as a second argument and as connection.req. Authenticating a socket used to mean re-reading the session cookie from connection.cookies and looking the session up by hand. Opt-in per route rather than running the app.use() chain, which would let an app's catch-all 404 handler answer every upgrade.
  • Path patterns (models/Router.bx; see docs/routing.md): a param can carry a regex constraint (/users/:id(\d+)), share a segment with literal text or other params (/flights/:from-:to, /api/v:version, /files/:name(.+).json), and a trailing *name captures the rest of the path. A route that needed a numeric id had to accept anything and reject it in the handler. A segment that is only :name is parsed as before, so /:user-id is still one param. A literal colon inside a path segment (/time/12:30) is now read as the start of a param, and a segment starting with * is a named wildcard. A wildcard or optional param is still final-segment only.
  • Request validation (new models/middleware/Validate.bx, bifs/boxExpressValidate.bx; see docs/validation.md): boxExpressValidate( schema ) checks req.body, req.query and req.params before the handler runs, converts values to the declared types, fills defaults, and answers 400 listing every problem. req.valid holds only the fields the schema names, so it can be passed to a model without a client slipping extra fields in. Types cover strings, numbers, booleans, email, URL, UUID, ISO dates, arrays and nested structs, with a validate function for anything else. A schema with an unknown type or rule name throws at registration.
  • One MIME table (new models/MimeTypes.bx): res.sendFile() and boxExpressStatic() each had their own, and they disagreed — sendFile() sent .avif, .ttf, .otf, .ogg, .map and .webmanifest as application/octet-stream, static files did the same for .csv and .zip. Both now use the union, which also gains .md, .yaml/.yml, .wav and .text.

GitHub ↗ About boxlang-express

boxlang-express 0.2.26

  • Session ids (models/middleware/Session.bx, models/stores/CacheStore.bx): the session cookie's value went to the store as-is, so with a cache-backed store a client could name any entry in that cache as its session — another feature's data, or the rate limiter's own counter, which the session save then wrote back stale (a limit of 3 let 10 of 10 requests through). Only values shaped like a generated id are looked up now, and CacheStore keys are prefixed boxexpress-session-. Upgrading signs out existing cache-backed sessions once, since their entries are under the old, unprefixed keys.
Full notes
  • Malformed % escapes (models/Request.bx, models/WebSocketConnection.bx, models/middleware/BodyParsers.bx): a cookie such as discount=50% failed every request carrying it with a
    1. Cookie and query values that won't decode are kept as raw text; a urlencoded body that won't decode gets a 400.
  • Request log (models/HttpBridge.bx): control characters in the logged path and client address are printed as ? — the decoded path could carry a newline or a terminal escape sequence and forge log lines.
  • Rate limiter (models/middleware/RateLimit.bx): the in-memory counter is updated atomically; concurrent requests could read the same count and run a few over the limit.
  • SSE (models/SseEmitter.bx): send() splits data on CR and CRLF as well as LF, so a bare CR can't start a new field, and blank lines inside the data are no longer dropped.
  • Uploads (models/middleware/Multipart.bx): name is no longer read out of filename="..." when a client sends filename first, and a part with no name gets a 400 instead of a 500.
  • STOMP (models/middleware/Stomp.bx, models/StompFrameCodec.bx):
    • Destinations, subscription ids, exchange bindings, topic patterns and listeners match case-sensitively. /ADMIN/feed and /admin/feed were one subscriber set, so an authorize() that compared case-sensitively could be sidestepped. Apps that relied on case-insensitive destinations need to normalize them.
    • sendToUser() compares logins exactly; alice also reached ALICE, and 7 reached 007.
    • Line breaks are dropped from headers sent to STOMP 1.0 subscribers (1.0 has no escapes), CR from 1.1 headers, and NUL from all of them.
  • Static files (models/middleware/StaticFiles.bx): a path holding a NUL falls through to the next handler instead of a 500.

GitHub ↗ About boxlang-express

bx-passkeys 0.3.1

  • A sign-in without userHandle (a non-discoverable passkey) failed with "The requested key [userHandle] was not located" in apps that load bx-compat-cfml. Fixed.
  • The specs run twice, plain and with bx-compat-cfml loaded.

GitHub ↗ About bx-passkeys

bx-passkeys 0.3.0

  • Browser answers are now verified by webauthn4j 0.32 (shipped in libs/ with Jackson 3) instead of the module's own CBOR, COSE and signature code, which is gone. Attestation statements of every format are checked for consistency.
  • Breaking: registration needs attestationObject. Every browser sends it, and client/passkeys.js always did; answers with only authenticatorData and the SPKI publicKey are refused.
  • register() and verify() report backupEligible and backedUp.
  • Answers from a cross-origin frame are refused at registration too, and an answer that says it's backed up but not backup eligible is refused.
  • userVerification, residentKey and origins settings are validated when the RelyingParty is built.
Full notes
  • The specs run in a BoxLang home of their own (bash scripts/test.sh), so an installed copy of the module can't stand in for the checkout.
  • The credential table and the CredentialStore interface are unchanged; passkeys registered with 0.2 keep working.

GitHub ↗ About bx-passkeys

cbpasskeys 0.1.0

  • First release: a CFML port of bx-passkeys 0.2.0 for ColdBox on Lucee 6+ and Adobe ColdFusion 2023+, with the same checks and API.
  • WireBox mappings RelyingParty@cbpasskeys, TableCredentialStore@cbpasskeys and MemoryCredentialStore@cbpasskeys; the store is picked with the credentialStore setting.
  • TableCredentialStore takes unicodeNames (default true) to bind passkey names as nvarchar, for drivers without national types.
  • MemoryCredentialStore compares credential ids case-sensitively.

GitHub ↗ About cbpasskeys

  • Lazy init vs. teardown (models/BoxExpress.bx): close() and the reload supervisor nulled the Scheduler and ClusterManager without the lazy-init lock, so a concurrent schedule() could hit a null or build a replacement nothing ever shut down (its non-daemon tick thread kept the JVM alive). Teardown now detaches both under the lock, and schedule()/getClusterManager() after close() throw BoxExpress.AppClosed. getScheduledJobs() and metrics() read them under the lock too.
Full notes
  • Clustered job ticks (models/Scheduler.bx): the election check ran outside any try, so a ClusterManager that failed to build cancelled the job's future ticks with nothing logged; it's now caught and the tick skipped. The tick no longer blocks on another thread building the ClusterManager, and a clustered schedule() builds it up front so config errors throw at the call.
  • Cluster election (models/cluster/ClusterManager.bx):
    • A manager whose own heartbeat is stale (older than half of peerIdleTimeoutSeconds) steps down and stops renewing its claim, so it can't keep acting as manager, or overwrite a successor's claim, after its peers have elected someone else.
    • Only a live election candidate keeps the role; a holder that restarted without clustered jobs left clustered jobs running nowhere until the claim expired.
    • Heartbeats carry a millisecond timestamp. Whole-second comparison expired live peers on scheduling jitter at a 1s idle timeout. Entries from older nodes are still read. The heartbeat interval floor is now 250ms, and peerIdleTimeoutSeconds under 1 is rejected.
    • The manager no longer rewrites its claim on every election check; the heartbeat renewal covers it.
    • getPeerPresence() and the relay connection mesh are keyed case-sensitively, so peers whose names differ only by case no longer collide.
    • A cache read that lands mid-write (FileSystemStore rewrites files in place) is retried before a peer is treated as gone, and an election check that still can't read every peer counts as not-manager for that round instead of electing from a partial view.

GitHub ↗ About boxlang-express

bx-passkeys 0.2.0

  • Breaking: with origins empty, only https://<rpId> is allowed now, not its subdomains. Set the new allowSubdomains: true (or list origins) to allow them.
  • Breaking: CredentialStore.updateUsage() returns a boolean and must save only while the counter moves forward (or stays 0), in one step. Custom stores need updating.
  • A cloned key that sent counter 0 got past the clone check and reset the stored counter to 0. Any counter that doesn't move forward is now refused.
  • Two sign-ins racing with the same counter can't both succeed: TableCredentialStore updates with sign_count < ?, and the memory store checks under its lock.
Full notes
  • Taking a challenge is locked per session, so one assertion can't be used by two parallel requests.
  • Registration and sign-in keep separate challenges, so starting a sign-in (in another tab, say) no longer cancels a registration in progress.
  • Registration requires the COSE key in authenticatorData; a browser SPKI key is checked against it rather than trusted on its own.
  • Credential ids over 1023 bytes are refused, ids are stored in canonical base64url, and transports are capped at 10 distinct entries.
  • maxPerUser is checked at registration too.
  • Sign-in refuses passkeys whose algorithm was taken out of algorithms.
  • SQL scripts: binary collations on credential_id and user_id (MSSQL, MySQL); name is bound as nvarchar so non-ASCII names survive on MSSQL.
  • MemoryCredentialStore matches user ids exactly and reads under its lock.
  • Module defaults live only in RelyingParty; one SecureRandom and Base64 coder are shared.

GitHub ↗ About bx-passkeys

bx-passkeys 0.1.0

  • First release, extracted from DismalThreads.
  • WebAuthn registration and sign-in with attestation "none", using only JDK crypto (java.security).
  • ES256 (P-256), Ed25519 and RS256 keys, read from the browser's SPKI getPublicKey() or the COSE key in attestationObject (built-in CBOR decoder).
  • Single-use, expiring challenges kept in a session struct you pass in.
  • Pluggable credential stores: TableCredentialStore and MemoryCredentialStore ship with the module.
  • passkeyRelyingParty() BIF and a browser client helper.

GitHub ↗ About bx-passkeys

  • Scheduler fixes (models/Scheduler.bx):
    • A run the stall watchdog gave up on could, when it finally returned, mark the job idle while its replacement was still running, so the next tick started a third run alongside it — the overlap guard was off for as long as that lasted. Each run now owns the job by id and only the current owner can release it.
    • A job that cancelled itself during its first immediate: true run could beat schedule() to storing the timer's future; cancel() then failed, was logged as a job failure, and the job kept running. Cancellation now works whichever side gets there first.
    • intervalMs is validated: anything but a whole number of milliseconds, 1 or more, throws BoxExpress.InvalidArgument. Before, the JDK rejected it only after the job was registered, leaving a dead job in getScheduledJobs() and metrics.
    • Job ids come from an atomic counter. Two concurrent schedule() calls could get the same id, and the second overwrote the first, leaving its timer ticking with no way to cancel it.
    • Two concurrent first calls to app.schedule() could each create a Scheduler, and jobs registered on the one that lost were never reachable by getScheduledJobs(), metrics or close(). The lazy creation (and app.getClusterManager()'s) is now locked.
    • New options.stallThresholdMs overrides the stall threshold.
    • running (in getScheduledJobs() and the boxexpress_scheduler_job_running metric) counts runs actually in flight.
  • Cluster manager election (models/cluster/ClusterManager.bx): the manager claim was only written when no live manager was found and never renewed, so it expired every peerIdleTimeoutSeconds * 3 and went to whichever instance checked next, and two instances checking at once could both claim it and both run a clustered job. Now a live manager keeps the role and renews its claim on each check and heartbeat, and with no live manager every instance picks the same winner — the lowest-named live election candidate — and only it writes the claim. Only instances that have checked (ones with clustered jobs) are candidates. See "How the manager is elected" in docs/cluster.md.
  • Heartbeat interval is a third of peerIdleTimeoutSeconds with a 1s minimum, down from a 5s minimum that made any idle timeout under 15s expire live peers between heartbeats.

GitHub ↗ About boxlang-express

  • Dependencies: bumped the vendored libs/undertow-core-*.jar from 2.4.3.Final to 2.4.4.Final, and wildfly-common from 1.5.4.Final to 2.0.1, the version Undertow 2.4.4 is built against. wildfly-common 2.x needs smallrye-common-expression, -net, -os and -ref, now vendored at 2.14.0 alongside the existing smallrye-common jars. The WebSocket shim is rebuilt against the new Undertow.

GitHub ↗ About boxlang-express