aboutsummaryrefslogtreecommitdiff
path: root/src/namestore/namestore_api_common.c
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-08-22 07:49:19 +0000
committerChristian Grothoff <christian@grothoff.org>2013-08-22 07:49:19 +0000
commita8c5af00cd450ce1c1bf5b2695e7168c526df071 (patch)
treea848ced6e20daf19548e5f9d3f8f7b77d1419269 /src/namestore/namestore_api_common.c
parent2cb19e37aa832394606af654199881f323f69dc8 (diff)
downloadgnunet-a8c5af00cd450ce1c1bf5b2695e7168c526df071.tar.gz
gnunet-a8c5af00cd450ce1c1bf5b2695e7168c526df071.zip
-expanding namestore API with pkey <-> zkey conversion functions
Diffstat (limited to 'src/namestore/namestore_api_common.c')
-rw-r--r--src/namestore/namestore_api_common.c36
1 files changed, 36 insertions, 0 deletions
diff --git a/src/namestore/namestore_api_common.c b/src/namestore/namestore_api_common.c
index b38a594db..4ca672f1e 100644
--- a/src/namestore/namestore_api_common.c
+++ b/src/namestore/namestore_api_common.c
@@ -954,4 +954,40 @@ GNUNET_NAMESTORE_query_from_public_key (const struct GNUNET_CRYPTO_EccPublicKey
954} 954}
955 955
956 956
957/**
958 * Convert public key to the respective absolute domain name in the
959 * ".zkey" pTLD.
960 * This is one of the very few calls in the entire API that is
961 * NOT reentrant!
962 *
963 * @param pkey a public key with (x,y) on the eliptic curve
964 * @return string "Y.X.zkey" where X and Y are the coordinates of the public
965 * key in an encoding suitable for DNS labels.
966 */
967const char *
968GNUNET_NAMESTORE_pkey_to_zkey (const struct GNUNET_CRYPTO_EccPublicKey *pkey)
969{
970 GNUNET_break (0); // not implemented
971 return NULL;
972}
973
974
975/**
976 * Convert an absolute domain name in the ".zkey" pTLD to the
977 * respective public key.
978 *
979 * @param zkey string "Y.X.zkey" where X and Y are the coordinates of the public
980 * key in an encoding suitable for DNS labels.
981 * @param pkey set to a public key with (x,y) on the eliptic curve
982 * @return #GNUNET_SYSERR if @a zkey has the wrong syntax
983 */
984int
985GNUNET_NAMESTORE_zkey_to_pkey (const char *zkey,
986 struct GNUNET_CRYPTO_EccPublicKey *pkey)
987{
988 GNUNET_break (0); // not implemented
989 return GNUNET_SYSERR;
990}
991
992
957/* end of namestore_common.c */ 993/* end of namestore_common.c */