NetBSD-Bugs archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
bin/59346: racoon's established IPsec-SA message reverses log polarity
>Number: 59346
>Category: bin
>Synopsis: racoon's established IPsec-SA message reverses log polarity
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: bin-bug-people
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Wed Apr 23 15:40:00 +0000 2025
>Originator: cagney
>Release: 10.1
>Organization:
>Environment:
NetBSD west 10.1 NetBSD 10.1 (GENERIC) #0: Mon Dec 16 13:08:11 UTC 2024 mkrepro%mkrepro.NetBSD.org@localhost:/usr/src/sys/arch/amd64/compile/GENERIC amd64
>Description:
The machine 192.1.2.45:
vioif1: flags=0x8843<UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST> mtu 1500
ec_capabilities=0x1<VLAN_MTU>
ec_enabled=0
address: 12:00:00:64:64:45
status: active
inet6 fe80::1000:ff:fe64:6445%vioif1/64 flags 0 scopeid 0x2
inet6 2001:db8:1:2::45/64 flags 0
inet 192.1.2.45/24 broadcast 192.1.2.255 flags 0
establishes an IPsec SA with the machine 192.1.2.23:
[root@west interop-racoon-10-aggr-initiator-ikev1]# racoonctl show-sa esp
192.1.2.23 192.1.2.45
esp mode=tunnel spi=255250(0x0003e512) reqid=0(0x00000000)
E: aes-cbc 488b0c0a 4350bb92 ea4bd669 86109375
A: hmac-sha1 bdf4f860 37bb2b09 5d950f94 29685420 9dbcc73e
seq=0x00000000 replay=4 flags=0x00000000 state=mature
created: Apr 23 15:16:00 2025 current: Apr 23 15:17:09 2025
diff: 69(s) hard: 43200(s) soft: 34560(s)
last: Apr 23 15:15:41 2025 hard: 0(s) soft: 0(s)
current: 0(bytes) hard: 0(bytes) soft: 0(bytes)
allocated: 0 hard: 0 soft: 0
sadb_seq=1 pid=1023 refcnt=0
192.1.2.45 192.1.2.23
esp mode=tunnel spi=1682472294(0x64487d66) reqid=0(0x00000000)
E: aes-cbc f15777c6 5ab30070 db458007 4f70e1c7
A: hmac-sha1 8a0238a9 2ca7dbab 2b47c692 e7f595d2 2664b455
seq=0x00000000 replay=4 flags=0x00000000 state=mature
created: Apr 23 15:16:00 2025 current: Apr 23 15:17:09 2025
diff: 69(s) hard: 43200(s) soft: 34560(s)
last: Apr 23 15:15:41 2025 hard: 0(s) soft: 0(s)
current: 0(bytes) hard: 0(bytes) soft: 0(bytes)
allocated: 0 hard: 0 soft: 0
sadb_seq=0 pid=1023 refcnt=0
looking carefully, at SRC, DST, and SPI, there's:
192.1.2.23 192.1.2.45 spi=255250(0x0003e512) inbound?
192.1.2.45 192.1.2.23 spi=1682472294(0x64487d66) outbound?
now compare that to the log messages emitted by racoon when things establish:
2025-04-23 15:15:59: INFO: initiate new phase 2 negotiation: 192.1.2.45[500]<=>192.1.2.23[500]
2025-04-23 15:15:59: INFO: IPsec-SA established: ESP/Tunnel 192.1.2.45[500]->192.1.2.23[500] spi=255250(0x3e512)
2025-04-23 15:15:59: INFO: IPsec-SA established: ESP/Tunnel 192.1.2.45[500]->192.1.2.23[500] spi=1682472294(0x64487d66)
note the `->`. The SPI is for 192.1.2.23->192.1.2.45, i.e., the reverse.
>How-To-Repeat:
>Fix:
Home |
Main Index |
Thread Index |
Old Index