IAIK ECC
version 2.18

iaik.security.ecc.util
Class Transforms

java.lang.Object
  extended byiaik.security.ecc.util.Transforms

public class Transforms
extends java.lang.Object

A collection of methods used to format the data


Constructor Summary
Transforms()
           
 
Method Summary
static byte[] i2osp(java.math.BigInteger fe, int size)
          Integer to Octet String Conversion Primitive or I2OSP as defined in P1363
static java.math.BigInteger xToBigInteger(ECPoint p)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

Transforms

public Transforms()
Method Detail

i2osp

public static byte[] i2osp(java.math.BigInteger fe,
                           int size)
Integer to Octet String Conversion Primitive or I2OSP as defined in P1363

Parameters:
fe - the integer to be converted
size - the length of the result array. if this parameter is shorter than the required size it will be ignored.
Returns:
the octet string as a byte[] in big-endian byte order: the most significant byte is in the zeroth element

xToBigInteger

public static java.math.BigInteger xToBigInteger(ECPoint p)
Returns:
the x coordinate of the specified point as an BigInteger according to the transformations in P1363

IAIK ECC
version 2.18

IAIK-ECC 2.18, (c) 2002 IAIK, (c) 2003 SIC