Uso de esta libreria para funciones criptograficas con curvas elipticas.

Dependencies:   mbed tinydtls lwip-mbed-2010

Revision:
0:7197fcdec294
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/main.cpp	Fri Feb 06 11:00:19 2015 +0000
@@ -0,0 +1,31 @@
+#include "mbed.h"
+Serial pc(USBTX, USBRX); // tx, rx
+DigitalOut myled(LED1);
+
+int main() {
+    
+    
+    //ecc_gen_pub_key(const uint32_t *priv_key, uint32_t *pub_x, uint32_t *pub_y)
+    /*
+ *  d: private key on the curve secp256r1 (32 bytes)
+ *  e: hash to sign (32 bytes)
+ *  k: random data, this must be changed for every signature (32 bytes)
+ *
+ * output:
+ *  r: r value of the signature (36 bytes)
+ *  s: s value of the signature (36 bytes)
+ *
+ * return:
+ *   0: everything is ok
+ *  -1: can not create signature, try again with different k.
+ */
+   /*uint32_t kPrivada=1147483647;
+    uint32_t hash=2147483117;
+    uint32_t ran=1147483147;
+    uint32_t firma_r;
+    uint32_t firma_s;
+    if (ecc_ecdsa_sign(&kPrivada, &hash, &ran, &firma_r, &firma_s)==0)  pc.printf("Hola Mundo\n");
+    else  pc.printf("Adios Mundo Cruel\n");
+    
+    */
+}