aboutsummaryrefslogtreecommitdiff
path: root/src/feature/nodelist/nickname.h
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2018-09-25 16:22:11 -0400
committerNick Mathewson <nickm@torproject.org>2018-09-25 16:22:11 -0400
commitefa978124f067bf75c33c4ff9bba8dbf2f54a4ef (patch)
tree877cacc564b746bafde6b9cda24d4ea78e1d1ac0 /src/feature/nodelist/nickname.h
parent5c86f3c297229515f125c0e06abdc689c90768f4 (diff)
downloadtor-efa978124f067bf75c33c4ff9bba8dbf2f54a4ef.tar.gz
tor-efa978124f067bf75c33c4ff9bba8dbf2f54a4ef.zip
Extract nickname-checking functions from router.c
Diffstat (limited to 'src/feature/nodelist/nickname.h')
-rw-r--r--src/feature/nodelist/nickname.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/feature/nodelist/nickname.h b/src/feature/nodelist/nickname.h
new file mode 100644
index 0000000000..86d4309918
--- /dev/null
+++ b/src/feature/nodelist/nickname.h
@@ -0,0 +1,19 @@
+/* Copyright (c) 2001 Matej Pfajfar.
+ * Copyright (c) 2001-2004, Roger Dingledine.
+ * Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson.
+ * Copyright (c) 2007-2018, The Tor Project, Inc. */
+/* See LICENSE for licensing information */
+
+/**
+ * \file nickname.h
+ * \brief Header file for nickname.c.
+ **/
+
+#ifndef TOR_NICKNAME_H
+#define TOR_NICKNAME_H
+
+int is_legal_nickname(const char *s);
+int is_legal_nickname_or_hexdigest(const char *s);
+int is_legal_hexdigest(const char *s);
+
+#endif