[HOME] [DOWNLOAD] [DOCS] [NEWS] [SUPPORT] [TIPS] [ISSUES] [DONATE]

Trouble creating onion-grater profile for LND.

I’m trying to create an onion-grater profile for LND, but I’m having some confusing trouble.

Here is the profile I’m using:

---
- exe-paths:
    - '*'
  users:
    - '*'
  hosts:
    - '*'
  commands:
    ADD_ONION:
      ## {{{ LND onion service.
      - pattern:     'NEW:ED25519-V3 Port=9735,9735'
        replacement: 'NEW:ED25519-V3 Port=9735,{client-address}:9735 Flags=DiscardPK'
      ## }}}

My problem is that onion-grater filters the command when lnd tries, but has no problem when I issue the same commands with nc.

lnd:

Jul 25 16:04:34 host onion-grater[11974]: 10.137.0.9:51714 (filter: 30_autogenerated): -> PROTOCOLINFO 1
Jul 25 16:04:34 host onion-grater[11974]: 10.137.0.9:51714 (filter: 30_autogenerated): <- 250-PROTOCOLINFO 1
Jul 25 16:04:34 host onion-grater[11974]: 10.137.0.9:51714 (filter: 30_autogenerated): <- 250-AUTH METHODS=NULL
Jul 25 16:04:34 host onion-grater[11974]: 10.137.0.9:51714 (filter: 30_autogenerated): <- 250-VERSION Tor="0.3.5.8"
Jul 25 16:04:34 host onion-grater[11974]: 10.137.0.9:51714 (filter: 30_autogenerated): <- 250 OK
Jul 25 16:04:34 host onion-grater[11974]: 10.137.0.9:51714 (filter: 30_autogenerated): -> AUTHENTICATE
Jul 25 16:04:34 host onion-grater[11974]: 10.137.0.9:51714 (filter: 30_autogenerated): <- 250 OK
Jul 25 16:04:34 host onion-grater[11974]: 10.137.0.9:51714 (filter: 30_autogenerated): -> ADD_ONION NEW:ED25519-V3 Port=9735,9735
Jul 25 16:04:34 host onion-grater[11974]: 10.137.0.9:51714 (filter: 30_autogenerated): command filtered: ADD_ONION NEW:ED25519-V3 Port=9735,9735
Jul 25 16:04:34 host onion-grater[11974]: 10.137.0.9:51714 (filter: 30_autogenerated): <- 510 Command filtered
Jul 25 16:04:34 host onion-grater[11974]: 10.137.0.9:51714 (filter: 30_autogenerated) disconnected: client quit

nc:

Jul 25 15:59:20 host onion-grater[11943]: 10.137.0.9:51518 (filter: 30_autogenerated): -> authenticate
Jul 25 15:59:20 host onion-grater[11943]: 10.137.0.9:51518 (filter: 30_autogenerated): <- 250 OK
Jul 25 15:59:23 host onion-grater[11943]: 10.137.0.9:51518 (filter: 30_autogenerated): -> ADD_ONION NEW:ED25519-V3 Port=9735,9735
Jul 25 15:59:23 host onion-grater[11943]: 10.137.0.9:51518 (filter: 30_autogenerated): rewrote command:
Jul 25 15:59:23 host onion-grater[11943]:     ADD_ONION NEW:ED25519-V3 Port=9735,9735
Jul 25 15:59:23 host onion-grater[11943]: to:
Jul 25 15:59:23 host onion-grater[11943]:     ADD_ONION NEW:ED25519-V3 Port=9735,10.137.0.9:9735 Flags=DiscardPK
Jul 25 15:59:23 host onion-grater[11943]: 10.137.0.9:51518 (filter: 30_autogenerated): <- (multi-line)
Jul 25 15:59:23 host onion-grater[11943]:     250-ServiceID=5tpmfl2asxky2vvbjx754h5scto63fqotue53ev6jbnvkzoff7itrgad
Jul 25 15:59:23 host onion-grater[11943]:     250 OK

Any ideas?

Dunno.

Maybe there is an extra whitespace somewhere?

Check the related LN source code.

[Imprint] [Privacy Policy] [Cookie Policy] [Terms of Use] [E-Sign Consent] [DMCA] [Investors] [Priority Support] [Professional Support]