Custom permissioning rules with a Hyperledger Besu plugin

A Besu plugin can register permissioning providers for node connections, transactions and node message propagation when local allowlists cannot express your rules. The maintenance cost of that plugin is what most teams underestimate.

On this page

When a Besu permissioning plugin is worth building instead of allowlists

If your consortium's rules can be written as a list of enodes and accounts, a file-based allowlist is the right tool and a plugin adds maintenance without adding control. A custom permissioning plugin is for the rules local permissioning cannot express, such as a policy that depends on context, time, or state the node has to evaluate at runtime. Besu's permissioning documentation says that to implement more complex permissioning rules than local permissioning allows, you should write your own plugin. Before you commit, write the consortium rule in one sentence and check whether a node permissions file or an account permissions file can express it. If either can, stop there.

Besu's PermissioningService lets a plugin register providers for three decisions: node connection permissioning, transaction permissioning, and node message permissioning. Node connection permissioning decides which peers a node will connect to. Transaction permissioning decides which transactions a node accepts. Node message permissioning controls what a node propagates to other nodes. The plugin services documentation gives a concrete case for the last one: stopping pending transactions from being forwarded to other nodes, which is a rule an allowlist cannot express because it does not see the transaction. Write the rule against the message type it gates, and confirm in the plugin services documentation which hooks your Besu version exposes.

The cost of a plugin is mostly ongoing. Each Besu upgrade can change the plugin API, so the plugin must be rebuilt and retested against every release your consortium adopts. Since Besu 26.8.0, the permissioning contracts sit in a separate besu-plugin-api-permissioning artifact that is re-exported by besu-plugin-api, so confirm your build dependencies after each upgrade. Ask the team that will own the plugin who reviews its decisions, how a rule change is rolled out across every member's nodes, and how a faulty rule is rolled back, because a plugin that rejects connections or transactions on one node but not another will split the consortium. Check the Besu releases page for the upgrade notes that affect plugin code.

What the PermissioningService lets a plugin decide

Besu's PermissioningService lets a plugin register providers at three points in the node's life: when peers connect, when transactions are accepted, and which messages are propagated to other nodes. Each provider answers a yes or no question, so the rules you write are only as good as the hooks your Besu version exposes.

Node connection permissioning

This provider decides whether a remote node may establish a peer connection with yours. It is the plugin equivalent of the nodes allowlist, but the decision is computed by code, so it can consider more than a static enode entry. Before relying on it, confirm the exact method signature and when Besu calls it in the Besu version you run, and test that a rejected peer stays disconnected after restarts. Pay attention to whether the check runs on inbound, outbound, or both connections.

Permissioning plugin docs

Transaction permissioning

This provider decides whether a transaction is allowed into the node's pool and therefore whether it can be included in a block. It is the natural place for rules that depend on the sender, the recipient, or the transaction content, which a file-based account list cannot express. Confirm which checks run at pool admission and which run again during block production, because a transaction accepted by one node may be rejected by another. Test rejected transactions with a second node that receives them from a peer.

Node message permissioning

This provider decides whether the node forwards a given message to other nodes. The Besu plugin documentation cites stopping pending transactions from being forwarded to other peers as an example. This matters for confidentiality, because a transaction that reaches an unapproved node can leak even when it is never mined. Confirm which message types the hook covers in your version, and verify with packet captures or peer logs that filtered messages are not sent.

Plugin API version coupling

The permissioning contracts moved into a separate artifact in Besu 26.8.0, re-exported through the main plugin API. A plugin compiled against an earlier API may need dependency changes before it builds or loads against 26.8.0 or later. Check the release notes for every Besu upgrade and rebuild the plugin against the matching API version before rolling it to validators. Plan this as part of the upgrade process, not after it.

Besu release notes

Behavior across operators

A plugin that rejects a transaction on one node does not stop other operators' nodes from accepting or propagating it, so rule differences can split the network's view of the mempool. Every member that enforces a rule needs the same plugin version and configuration, and the plugin must produce the same decisions for the same input. Ask each member how it will deploy and verify the plugin, and who approves changes to the rule set.

How file-based permissioning differs from a plugin

The main question is whether your rules can be written as static lists that every node reads from a local file, or whether they need logic that a plugin must evaluate. Besu's local permissioning gives each node a permissions configuration file with two parts: node permissioning, which restricts connections to known participants, and account permissioning, which covers onboarding rules, suspending accounts and restricting actions. Both are configured per node and checked by Besu itself, with no custom code. For many consortia that is enough, and it is the cheaper option to run. Confirm the exact keys and their current behavior in the Besu permissioning docs before you design around them, because the file format and runtime update paths have changed across releases.

Local permissioning stops where a rule depends on something a static file cannot express. Examples include an account that is allowed only during a contractual period, a transaction that must be checked against an external registry or sanctions feed, a limit that depends on the state of another system, or a node admitted only after a check in an identity service. A plugin registers its own providers through Besu's PermissioningService, so the decision logic runs inside the node. Before choosing a plugin, list each rule and ask whether it can be expressed as a list of identities that changes rarely. Rules that need time, external data or conditional logic are the ones that justify plugin work. Ask your Besu maintainers to confirm which hooks the current release exposes for each rule type.

The choice also determines how hard consistency across the consortium will be. A file-based list is easy to review, diff and distribute, and every operator can check the same content. A plugin means every operator runs the same plugin version, the same configuration and the same external dependencies, and a difference in any of them can cause one node to accept a transaction or connection that another rejects. Plan for that from the start: pin plugin and Besu versions together, test changes against a shared test network, and agree how a rule change is rolled out across all members. The cost of a plugin is the ongoing discipline of keeping that logic identical everywhere, not only the initial build.

Choosing between allowlists, plugin rules and a fork

Local permissioning is the first option to evaluate. Each node reads a permissions configuration file that controls node connections (restricting peers to known participants) and account permissioning (onboarding rules, suspending accounts and restricting actions). Your team maintains the files on every node, and Besu's own release process covers the code that reads them, so there is no custom code to carry between releases.

  • Rule types it fits: static lists of enodes and accounts, plus suspension and onboarding rules that the documented file format expresses.
  • Who maintains it: your operations team edits the files, and the consortium agrees the change process that keeps every member's lists aligned.
  • Release impact: the files continue to work across upgrades as long as the release notes do not change the format, so each release needs a read-through of the notes rather than a code review.
  • Limit: rules that depend on live state, external systems or message-level decisions are outside what the file format expresses.
  • Operational cost: recurring effort is list maintenance and coordination across members.

Before relying on this tab, confirm the current file format and supported fields against the Besu permissioning documentation for your target release.

How a permissioning plugin is built and deployed

The build sequence turns a permissioning requirement into a plugin that is version-matched to Besu, deployed identically on every node and proven on a test network before any member relies on it.

  1. Confirm the Besu version and JDK requirement

    Before writing code, the engineering lead records the Besu release that every node runs and the JDK it needs. The Besu 26.6.0 release notes state that Besu requires JDK 25 to build and run, so the build environment and the nodes must both meet that requirement. Pick a target release from the published calendar, then check its release notes for plugin API changes. The step is complete when a written version matrix lists the Besu release, the JDK and the plugin build target, and every operator has confirmed it can run them.

  2. Pin the plugin API dependency

    The developer adds the Besu plugin API to the build file at the exact version matching the chosen Besu release, and does not use floating version ranges. From Besu 26.8.0, the permissioning contracts sit in a separate besu-plugin-api-permissioning artifact that besu-plugin-api re-exports, so the build must resolve the artifact the release notes name. The check is a clean build from an empty cache that produces the same plugin archive on two machines, with the dependency tree recorded in version control.

  3. Implement a provider for each permission type

    The developer registers a provider through the PermissioningService for each control the requirement needs: node connection permissioning, transaction permissioning, or node message permissioning. Message permissioning is the control that can stop pending transactions being forwarded to other nodes. Each provider should return allow or deny decisions from a single, documented rule set, and log the reason for each denial. The step is complete when each rule has a unit test covering the allow and deny cases, and the rule set matches the written requirement one to one.

  4. Package and deploy the same plugin to every node

    The release engineer packages the plugin with a checksum and places the identical file in the Besu plugins directory on every node, including validators, RPC nodes and bootnodes. A plugin that differs between members can make the network disagree about who may connect or transact. Record the file hash in the change log for each node. The check is that every node reports the same plugin version and hash after restart, so no node runs an older rule set.

  5. Confirm the plugin loads on each node

    After each restart, the operator reviews the Besu startup logs to confirm the plugin was discovered and registered its permissioning providers without errors. A plugin that fails to load can leave a node running without the intended rules, so this check is required on every node, not a sample. The step is complete when the log record for each node shows the plugin name, version and registration, and any warnings have been resolved or accepted in writing.

  6. Test allowed and denied behavior on a test network

    On a non-production network with the same Besu version and plugin, the test team runs scripted cases: an approved node should connect, an unapproved node should be refused, an allowed transaction should be accepted, and a denied transaction should be rejected and not forwarded to peers. Each case records the expected and observed result. The step is complete when every case matches the written specification, and any mismatch has a fix and a rerun. Include the cases that prove propagation is blocked, since a denial at submission does not prove that other nodes never receive the transaction.

  7. Go live with a rollback plan and monitoring

    Before production, the operator agrees a rollback path, which is to restore the previous plugin file and restart nodes, and confirms it on the test network. The team then rolls out node by node, checking each node's logs and peer counts after restart. Rejections should be monitored through the node metrics and logs so that unexpected denials appear quickly. The step is complete when every node runs the approved plugin, the rollback has been rehearsed, and the change record names the owner who approves future rule changes.

How a plugin decision fits into node and transaction flow

The diagram starts at two entry points: a peer connection attempt and a submitted transaction. Each hits Besu's permissioning checks, where local permissioning files act as a first layer and the plugin's PermissioningService providers act as a second layer for node connection, transaction and message propagation decisions. Only when every check allows the action does Besu proceed. Check which provider owns each decision, and confirm that the plugin's deny outcome is logged and matched by the local files your consortium maintains.

Local files run first, then plugin providers decide connections, transactions and message propagation.

Security risks a custom permissioning plugin introduces

A permissioning plugin runs inside the Besu node process and decides which peers, transactions and messages get through. The risks below follow from that position: the code is trusted, the data it reads is sensitive, its failure mode can halt or open the network, and each release changes the node's access rules.

Code runs inside the node

A plugin is loaded into the same process that holds the node key and serves JSON-RPC, so a defect or malicious change in the plugin has the same reach as Besu itself. Treat the plugin as privileged code. Check who can merge changes, review every dependency it pulls in, and confirm the node process runs with the least file and network access it needs. Ask the plugin author to document every class and service the plugin registers.

Permissioning plugin services

Decision data becomes an attack target

A rule that calls an external list, directory or database must authenticate to it, and that credential sits in the node's reach. Scope the plugin's read access to the specific allowlist or group data it needs, and store any credential outside the plugin's configuration files. Confirm which account identities the rule logs and whether those logs leave your environment.

Fail-closed or fail-open on outage

If the rule source is unreachable, a plugin must either reject connections and transactions or keep serving with stale decisions. Neither is free: fail-closed can stop a validator from peering, while fail-open can admit a party that was already suspended. Decide the behavior per permission type, test it by blocking the source during a rehearsal, and record the decision in the runbook.

Cached decisions and staleness

Plugins that cache answers can keep allowing an account after it has been removed from the source. Set a maximum age for cached decisions, and make suspension or removal flush the cache rather than waiting for expiry. Verify this with a test where you remove an account and confirm the node stops accepting its transactions within the window you agreed.

Plugin release change control

Besu ships a new calendar release roughly monthly, and the plugin API can move between releases, so a plugin built for one version may fail or behave differently on the next. Pin the Besu version and plugin version together, test each combination on a non-production network, and keep the previous plugin build available for rollback. Confirm the plugin API changes in the release notes before any upgrade.

Besu release notes

Consistency across members

When one organization runs a custom rule and others run file-based lists, the network can split: nodes disagree about which peers are valid and transactions propagate unevenly. Agree in writing which members run the same plugin, which version, and what the rule source is. Require each member to report the plugin build it runs as part of the change process.

Questions teams ask before building a permissioning plugin

How much effort does a custom Besu permissioning plugin take to build?

Effort depends less on the first version than on what the plugin must decide and how many node types and transaction paths it touches. A plugin that only answers connection checks is a small Java codebase, while one that also filters transactions and controls which pending transactions are propagated needs more design, more test cases and more review of how Besu calls each provider. Ask any partner for a written scope that lists each permissioning provider the plugin registers, the rules behind each one, the external data it reads, and the test environment it will be proven against. Build cost is one-time, but the maintenance cost described in the next questions recurs for as long as the network runs.

What makes ongoing maintenance of a Besu plugin expensive?

The main recurring driver is the Besu release cadence. Besu uses calendar version numbers and ships roughly monthly, so a plugin built against one release must be rebuilt, retested and redeployed as the client moves forward. API changes add work on top of that. Besu 26.8.0 moved the permissioning contracts of the plugin API into a separate besu-plugin-api-permissioning artifact, re-exported by besu-plugin-api, so a plugin that depends on those types has to be checked against the new build layout. Budget for each upgrade cycle as a recurring activity, and ask a partner how many release versions their maintenance proposal covers and how they handle breaking changes in the plugin API.

Does a consortium need to test a permissioning plugin together?

Yes, in most consortium setups. A permissioning plugin that runs on one member's node but not on the others can cause peers to disagree about which connections or transactions are allowed, which shows up as partial networks, stalled propagation or confusing rejections. Testing should therefore cover every member's Besu version, plugin build and configuration, ideally on a shared test network that mirrors production topology. Each member also needs a change process so that a plugin update is rolled out in an agreed order. The cost of this coordination depends on how many organizations run the network and how often their release schedules differ.

What does the work need from our team?

Expect to supply several things before a partner writes code. You need an owner for the permissioning policy who can state the rules in plain terms, including who may connect, which accounts may transact and what must never be forwarded. You also need access to the identity or registry data the plugin will read, a test network you can change without touching production, and a named person to review each release. Engineers who know the Besu codebase and the plugin service APIs are needed to review code, even when a partner does the build. Without these inputs, scope tends to grow during testing.

Can our own engineers build and maintain the plugin?

They can, if the team has Java experience, has worked with Besu's plugin services and can keep up with the release cadence. The practical test is whether two or more engineers can each take a Besu upgrade from start to finish, including running the consortium test plan. A single engineer who understands the plugin is a maintenance risk, because the plugin will need changes on the schedule of Besu releases, not the schedule of the project. Many teams split the work: an internal owner keeps the policy and runs upgrades, and an outside partner builds the first version and supports complex changes. Confirm your team's capacity before deciding.

When is a file-based allowlist enough instead of a plugin?

Local permissioning is often enough when your rules are a fixed list of nodes and accounts that changes rarely. Besu's documentation describes node permissioning, which restricts connections to known participants, and account permissioning, which covers onboarding rules, suspending accounts and restricting actions. The Besu permissioning documentation points to writing your own plugin when you need more complex rules than these allow. Typical triggers are rules that depend on live external data, checks that must differ by transaction type, or propagation limits that a file cannot express. Read the Besu permissioning documentation before committing to a plugin.

What should we confirm before asking for a plugin quote?

Ask the partner to confirm the Besu versions the plugin will target and the process for moving to new releases, since the calendar release cycle sets the pace of work. Confirm which of the three PermissioningService provider types you need: node connection, transaction, or node message permissioning. Ask how the plugin will be tested across all member nodes and who signs off on each release. Finally, ask for the recurring support terms separately from the build, so you can compare one-time and ongoing costs. A written scope is the basis for any quote.

Limits to confirm in your environment

A plugin ties your permissioning logic to a specific Besu release, Java runtime and plugin API. Each card below is a check to run with the vendor docs or on your own test network before you commit to a design.

Besu version and JDK 25

Besu 26.6.0 requires JDK 25 to build and run, so your plugin build, your nodes and your CI images must all target that runtime. Confirm the exact Besu release you will run in production, then confirm your plugin compiles and starts against it. Check that your organization's approved Java distribution and build tooling support JDK 25 before the first build.

Besu releases

Hooks in your chosen release

Confirm that the PermissioningService provider types you need, for node connection, transaction and node message permissioning, exist in the release you plan to run. Do not assume a hook from the docs applies to an older or newer version. Build a small test plugin that registers each provider and verify that Besu calls it under the conditions you expect.

Permissioning plugin docs

Plugin API artifact changes

Besu 26.8.0 moved the permissioning contracts into a separate besu-plugin-api-permissioning artifact that besu-plugin-api re-exports. Check which artifact your build depends on and whether your plugin still compiles when you change the Besu version. Pin your dependency versions and record them in your build configuration so a release does not silently change the API your plugin links against.

Upgrade impact on the plugin

Each monthly Besu release can change plugin behavior, and an upgraded database cannot be opened by an older Besu version. Before any upgrade, ask which plugin APIs changed, rebuild the plugin against the new release, and run your test network through the upgrade. Keep a database backup and a tested rollback path, because a plugin rebuilt for one release may not load on the one you return to.

Identical logic across members

Every consortium member must run logic that gives the same answer for the same node or transaction. If one member runs a different plugin version, or no plugin, nodes may accept peers or transactions that others reject, which can split network behavior. Agree on a single plugin version, a shared build artifact and a change process before go-live, and test cross-member peering with each release.

Ownership and support after go-live

A custom plugin is code your organization maintains, not part of the Besu product. Confirm who owns the source, who reviews changes, who tests Besu upgrades against it and who responds when it fails during a release. Ask whether your support arrangements cover a self-written plugin, and budget for ongoing maintenance as a recurring cost, not a one-time build.

How DeployOpen scopes a Besu permissioning plugin

A DeployOpen plugin engagement starts with a written scope that fixes four things before any code is written: the rules the plugin enforces, the exact Besu version it targets, the test plan that proves those rules hold, and who maintains the plugin after handover. The rules are listed one by one with the Besu permissioning hook each one uses, such as node connection permissioning, transaction permissioning or node message permissioning. The Besu version matters because the plugin API changes between releases. Besu 26.8.0 moved the permissioning contracts into a separate besu-plugin-api-permissioning artifact, so the build dependencies and the release the plugin is tested against must be named in the scope. Confirm with your team which Besu release your network runs and which releases you plan to adopt within the next year.

The test plan is agreed as part of the scope, not left for later. It covers allowed and denied connections, transactions from approved and unapproved accounts, and the propagation behavior the plugin is meant to control, run against a private test network that mirrors your consortium's configuration. Deliverables typically include the plugin source, build and packaging instructions, configuration reference, test results and an operations runbook that explains how to deploy the plugin on each node and what to do when a rule blocks legitimate traffic. The written scope should also name who owns each recurring task: upgrading the plugin for new Besu releases, reviewing rule changes, and keeping every consortium member on the same plugin version. Ask DeployOpen to state these responsibilities explicitly and to name the party that signs off on each rule change.

Most engagements are fixed-scope, so the quote follows from the written rules, the number of networks and nodes, and the test coverage you specify. Ongoing work is handled through retainers: upgrades to new Besu releases, and continuous testing of the plugin as your network changes. DeployOpen does not publish a price list, and it does not claim partner status with the Besu project or the Linux Foundation. Before you sign, ask for the scope document, the deliverables list, the test plan and the maintenance responsibilities in writing, and confirm how changes to scope after kickoff are priced and approved.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.