Re: [sidr] Another potential DOS attack on RP software?

Tim Bruijnzeels <tim@ripe.net> Thu, 23 January 2014 13:38 UTC

Return-Path: <tim@ripe.net>
X-Original-To: sidr@ietfa.amsl.com
Delivered-To: sidr@ietfa.amsl.com
Received: from localhost (ietfa.amsl.com [127.0.0.1]) by ietfa.amsl.com (Postfix) with ESMTP id 9DF2E1A03E3 for <sidr@ietfa.amsl.com>; Thu, 23 Jan 2014 05:38:23 -0800 (PST)
X-Virus-Scanned: amavisd-new at amsl.com
X-Spam-Flag: NO
X-Spam-Score: -2.435
X-Spam-Level:
X-Spam-Status: No, score=-2.435 tagged_above=-999 required=5 tests=[BAYES_00=-1.9, RP_MATCHES_RCVD=-0.535] autolearn=ham
Received: from mail.ietf.org ([4.31.198.44]) by localhost (ietfa.amsl.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id 6UnAu1KJ5jBG for <sidr@ietfa.amsl.com>; Thu, 23 Jan 2014 05:38:21 -0800 (PST)
Received: from kaka.ripe.net (kaka.ripe.net [IPv6:2001:67c:2e8:11::c100:1347]) by ietfa.amsl.com (Postfix) with ESMTP id B0CBF1A0114 for <sidr@ietf.org>; Thu, 23 Jan 2014 05:38:21 -0800 (PST)
Received: from titi.ripe.net ([193.0.23.11]) by kaka.ripe.net with esmtps (TLSv1:AES256-SHA:256) (Exim 4.72) (envelope-from <tim@ripe.net>) id 1W6KU5-0006A0-Ec; Thu, 23 Jan 2014 14:38:18 +0100
Received: from puppy.ipv6.ripe.net ([2001:67c:2e8:1::c100:1e6] helo=[IPv6:::1]) by titi.ripe.net with esmtps (TLSv1:AES128-SHA:128) (Exim 4.72) (envelope-from <tim@ripe.net>) id 1W6KU5-0002jx-6f; Thu, 23 Jan 2014 14:38:17 +0100
Mime-Version: 1.0 (Mac OS X Mail 6.6 \(1510\))
Content-Type: text/plain; charset="us-ascii"
From: Tim Bruijnzeels <tim@ripe.net>
In-Reply-To: <52E10F1A.8030800@smail.inf.h-brs.de>
Date: Thu, 23 Jan 2014 14:38:19 +0100
Content-Transfer-Encoding: quoted-printable
Message-Id: <8980320B-8C8C-45E4-B2E1-C03A9AB26EB5@ripe.net>
References: <CF03F5F3.5FD30%keyupate@cisco.com> <52E10F1A.8030800@smail.inf.h-brs.de>
To: Demian Rosenkranz <drosen2s@smail.inf.h-brs.de>
X-Mailer: Apple Mail (2.1510)
X-RIPE-Spam-Level: ---
X-RIPE-Spam-Report: Spam Total Points: -3.5 points pts rule name description ---- ---------------------- ------------------------------------ -1.0 ALL_TRUSTED Passed through trusted hosts only via SMTP -0.6 RP_MATCHES_RCVD Envelope sender domain matches handover relay domain -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000]
X-RIPE-Signature: 784d7acfe6559f2a0b602ec6519a07195601ed23c0128b672020f77646c2d409
Cc: sidr@ietf.org
Subject: Re: [sidr] Another potential DOS attack on RP software?
X-BeenThere: sidr@ietf.org
X-Mailman-Version: 2.1.15
Precedence: list
List-Id: Secure Interdomain Routing <sidr.ietf.org>
List-Unsubscribe: <https://www.ietf.org/mailman/options/sidr>, <mailto:sidr-request@ietf.org?subject=unsubscribe>
List-Archive: <http://www.ietf.org/mail-archive/web/sidr/>
List-Post: <mailto:sidr@ietf.org>
List-Help: <mailto:sidr-request@ietf.org?subject=help>
List-Subscribe: <https://www.ietf.org/mailman/listinfo/sidr>, <mailto:sidr-request@ietf.org?subject=subscribe>
X-List-Received-Date: Thu, 23 Jan 2014 13:38:23 -0000

Hi Demian,

On Jan 23, 2014, at 1:46 PM, Demian Rosenkranz <drosen2s@smail.inf.h-brs.de> wrote:

> Hi,
> 
> I'm thinking about another potential DoS attack. An entity which owns a CA certificate has the possibility to generate a huge hierarchy of further CA certificates without any limitation (as far as I know).
> 

As far as I remember there are no formal restrictions regarding either the number of child CA certificates issued by a CA, or the length of the chain.  

> In contrast to the generation of a huge amount of ROAs, this attack isn't limited regarding the number of objects/certificates.
> 
> I.e. a compromised/bad entity owns a /16 prefix and generates 10000 CA certificates and hand down this prefix until the lowest CA certificate and generates 2^8 ROAs, a relying party software would be forced to check this hierarchy 2^8 times.

Some say that the same resource 'should' not appear on multiple child CA certificates, however in practice this can happen in case of a child key roll, and a make-before-break resource transfer. There is no notification about the reason, so RPs have a hard time guessing. In short: our RP doesn't care about resources appearing on multiple child CA certs. If the certificates are valid, the duplicate resource is valid for both branches.. if the parent disagrees, they should revoke / re-issue as needed.

That said, if one wants avoid duplicating resources in an attack like this there is always IPv6.. And then it's of course possible that it wasn't intended as an attack at all, but some over zealous CA goes granular way beyond present day BGP --- eg. giving ghostbusters to all their v6 end users ;)

> Of course, this is kind of a blunt attack but without making any provisions, this "local cache flooding" could lead to a disturbance of all (worst case) local caches for a certain time. Some smaller RP could be slower in remedying this.

While I don't think we have formal restrictions, I can imagine certain mitigations if this would become a serious threat:
= Parent of the offending CA could revoke the certificate (if abuse is defined in terms of use, talking doesn't help, etc.., reactive by nature though)

= RPs could limit the maximum length of the cert chain, or even number of CA certs issued by CA certs they are willing to accept
      - e.g. pro-actively quarantine 'spam-CAs' like this, and allow the end-user to override
      - or re-actively.. proceed, but warn and allow user to disregard
      - or a mix of both of course with some thresholds, prob. allowing the RIRs to issue a bit more 
= RPs should probably employ strategies to ensure that a lot of work in one part of the tree does not block validation of the remaining tree (if resources don't overlap).

> Are there any restriction to this attack I've missed? Any feedback is very welcome!

I would say that been though it's entirely possible to attack the rpki by producing many objects, it's not feasible to do this *covertly*. This will get get you noticed, quickly.

So while I see the value of thinking about these scenarios and possible ways to mitigate them - thank you :) - I am not convinced that we should go overboard in terms of best practices for RPs, or general restrictions for CAs, at this time. I would consider possible *covert* attack vectors on the rpki infrastructure to be much more serious though.

Cheers
Tim