1<?php
2
3/**
4 * ECParameters
5 *
6 * From: https://tools.ietf.org/html/rfc5915
7 *
8 * PHP version 5
9 *
10 * @author    Jim Wigginton <terrafrost@php.net>
11 * @copyright 2016 Jim Wigginton
12 * @license   http://www.opensource.org/licenses/mit-license.html  MIT License
13 * @link      http://phpseclib.sourceforge.net
14 */
15
16namespace phpseclib3\File\ASN1\Maps;
17
18use phpseclib3\File\ASN1;
19
20/**
21 * ECParameters
22 *
23 *  ECParameters ::= CHOICE {
24 *    namedCurve         OBJECT IDENTIFIER
25 *    -- implicitCurve   NULL
26 *    -- specifiedCurve  SpecifiedECDomain
27 *  }
28 *    -- implicitCurve and specifiedCurve MUST NOT be used in PKIX.
29 *    -- Details for SpecifiedECDomain can be found in [X9.62].
30 *    -- Any future additions to this CHOICE should be coordinated
31 *    -- with ANSI X9.
32 *
33 * @author  Jim Wigginton <terrafrost@php.net>
34 */
35abstract class ECParameters
36{
37    const MAP = [
38        'type' => ASN1::TYPE_CHOICE,
39        'children' => [
40            'namedCurve' => ['type' => ASN1::TYPE_OBJECT_IDENTIFIER],
41            'implicitCurve' => ['type' => ASN1::TYPE_NULL],
42            'specifiedCurve' => SpecifiedECDomain::MAP
43        ]
44    ];
45}
46