'Returns information about the curve used for an EC key
:raises:
ValueError - when the key is not an EC key
:return:
A two-element tuple, with the first element being a unicode string
of "implicit_ca", "specified" or "named". If the first element is
"implicit_ca", the second is None. If "specified", the second is
an OrderedDict that is the native version of SpecifiedECDomain. If
"named", the second is a unicode string of the curve name.'

@property
def curve(self):

    if (self.algorithm != u'ec'):
        raise ValueError(unwrap(u'\n                                                                Only    EC    keys    have    a    curve,    this    key    is    %s\n                                                                ', self.algorithm.upper()))
    params = self[u'private_key_algorithm'][u'parameters']
    chosen = params.chosen
    if (params.name == u'implicit_ca'):
        value = None
    else:
        value = chosen.native
    return (params.name, value)
