Bug 121373 - [ipsec] New IPSEC & IPV6 & AH+ESP Broken
Summary: [ipsec] New IPSEC & IPV6 & AH+ESP Broken
Status: Closed Overcome By Events
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: 7.0-RELEASE
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-bugs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-03-05 00:20 UTC by crahman
Modified: 2019-05-20 10:58 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description crahman 2008-03-05 00:20:02 UTC
One can't run ipsec with both esp + ah on 7.0-RELEASE with ipv6.  Trying to will
produce the kernel printf:

 kernel: ip6_output (ipsec): error code 22

and no output from the interface.

The problem looks to be here, in ipsec_output.c, ipsec_process_done():

       /*
         * If there's another (bundled) SA to apply, do so.
         * Note that this puts a burden on the kernel stack size.
         * If this is a problem we'll need to introduce a queue
         * to set the packet on so we can unwind the stack before
         * doing further processing.
         */
        if (isr->next) {
                ipsec4stat.ips_out_bundlesa++;
                return ipsec4_process_packet(m, isr->next, 0, 0);
        }

So for the second SA we try to apply it with ipsec4_process_packet(), which fails when handed an ipv6 packet.  By the way, things work fine with ipv4.

How-To-Repeat: Set up an association between two ipv6 hosts that calls for esp+ah.
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2008-03-05 00:26:16 UTC
Responsible Changed
From-To: freebsd-bugs->freebsd-net

Over to maintainer(s).
Comment 2 Bjoern A. Zeeb freebsd_committer freebsd_triage 2008-03-08 23:06:45 UTC
Responsible Changed
From-To: freebsd-net->bz

Take this. Might take a few days before I can come up with a patch.
Comment 3 dfilter service freebsd_committer freebsd_triage 2008-03-14 11:09:17 UTC
bz          2008-03-14 11:09:11 UTC

  FreeBSD src repository

  Modified files:
    sys/netinet6         ip6_output.c 
  Log:
  Replace the function name in two identical printfs
  by __func__, __LINE__ so we can distinguish them
  when people report a problem.
  
  PR:             121373
  MFC after:      5 days
  
  Revision  Changes    Path
  1.115     +4 -2      src/sys/netinet6/ip6_output.c
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 4 Gavin Atkinson freebsd_committer freebsd_triage 2008-06-11 14:04:28 UTC
State Changed
From-To: open->patched

This has been fixed in HEAD and RELENG_7 but is still awaiting MFC 
to RELENG_6
Comment 5 Bjoern A. Zeeb freebsd_committer freebsd_triage 2008-06-11 14:14:58 UTC
On Wed, 11 Jun 2008, gavin@FreeBSD.org wrote:

> Synopsis: [ipsec] New IPSEC & IPV6 & AH+ESP Broken
>
> State-Changed-From-To: open->patched
> State-Changed-By: gavin
> State-Changed-When: Wed Jun 11 13:04:28 UTC 2008
> State-Changed-Why:
> This has been fixed in HEAD and RELENG_7 but is still awaiting MFC
> to RELENG_6
>
> http://www.freebsd.org/cgi/query-pr.cgi?pr=121373

What makes you think that it was? I cannot remember I had found the
time for IPSec work lately (unfortunately).

Could you please change it back to open?

-- 
Bjoern A. Zeeb              Stop bit received. Insert coin for new game.
Comment 6 Gavin Atkinson freebsd_committer freebsd_triage 2008-06-11 14:37:25 UTC
State Changed
From-To: patched->open

Back to open, on bz@ request - I misread the PR, this was never patched
Comment 7 Bjoern A. Zeeb freebsd_committer freebsd_triage 2014-05-18 06:03:13 UTC
Responsible Changed
From-To: bz->gnn

I shall not use bugzilla (at least until we will have a CLI).
Comment 8 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 07:59:55 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped
Comment 9 Andrey V. Elsukov freebsd_committer freebsd_triage 2019-05-20 10:58:28 UTC
This was fixed in 11.0+ releases. Now both IPv4 and IPv6 supports chains of ISRs.