@VisibleForTesting
  void requestENR(final DiscoveryPeer peer) {
    final Consumer<PeerInteractionState> action =
        interaction -> {
          final EnrRequestPacketData data = enrRequestPacketDataFactory.create();
          createPacket(
              PacketType.ENR_REQUEST,
              data,
              enrPacket -> {
                final Bytes enrHash = enrPacket.getHash();
                // Update the matching filter to only accept the ENRResponse if it echoes the hash
                // of our request.
                final Predicate<Packet> newFilter =
                    packet ->
                        packet
                            .getPacketData(EnrResponsePacketData.class)
                            .map(enr -> enr.getRequestHash().equals(enrHash))
                            .orElse(false);
                interaction.updateFilter(newFilter);

                sendPacket(peer, enrPacket);
              });
        };

    // The filter condition will be updated as soon as the action is performed.
    final PeerInteractionState peerInteractionState =
        new PeerInteractionState(action, peer.getId(), PacketType.ENR_RESPONSE, packet -> false);
    dispatchInteraction(peer, peerInteractionState);
  }
Initiates an enr request cycle with a peer.

@param peer The targeted peer.
ethereum/p2p/src/main/java/org/hyperledger/besu/ethereum/p2p/discovery/internal/PeerDiscoveryController.java