[][src]Trait zerocaf::traits::ops::Double

pub trait Double {
    type Output;
#[must_use]
    fn double(self) -> Self::Output;
}

Trait that represents the Point doubling operation for any type of Point that is used on the lib.

This trait is implemented following the rules that mandate over the Type that is being implemented.

Associated Types

type Output

Loading content...

Required methods

#[must_use] fn double(self) -> Self::Output

Performs the point-doubling operation over the coordinates which this trait has been implemented for.

Loading content...

Implementors

impl<'a> Double for &'a EdwardsPoint[src]

type Output = EdwardsPoint

fn double(self) -> EdwardsPoint[src]

Performs the point doubling operation ie. 2*P over the Twisted Edwards Extended Coordinates.

This implementation is specific for curves with a = -1 as Sonny is. Source: 2008 Hisil–Wong–Carter–Dawson, http://eprint.iacr.org/2008/522, Section 3.1. Cost: 4M+ 4S+ 1D

impl<'a> Double for &'a ProjectivePoint[src]

type Output = ProjectivePoint

fn double(self) -> ProjectivePoint[src]

Double the given point following: This implementation is specific for curves with a = -1 as Sonny is.

/// Bernstein D.J., Birkner P., Joye M., Lange T., Peters C. (2008) Twisted Edwards Curves. In: Vaudenay S. (eds) Progress in Cryptology – AFRICACRYPT 2008. AFRICACRYPT 2008. Lecture Notes in Computer Science, vol 5023. Springer, Berlin, Heidelberg. See: https://eprint.iacr.org/2008/013.pdf - Section 6.

Cost: 3M+ 4S+ +7a + 1D.

impl<'a> Double for &'a RistrettoPoint[src]

type Output = RistrettoPoint

fn double(self) -> RistrettoPoint[src]

Performs the point doubling operation ie. 2*P over the Twisted Edwards Extended Coordinates.

This implementation is specific for curves with a = -1 as the isomorphic twist is. Source: 2008 Hisil–Wong–Carter–Dawson, http://eprint.iacr.org/2008/522, Section 3.1. Cost: 4M+ 4S+ 1D

Loading content...