mirror of
https://gitlab.torproject.org/tpo/core/tor.git
synced 2024-12-06 19:41:15 +01:00
Add a script to run trunnel on the trunnel files.
Also, re-run the latest trunnel. Closes ticket 13242
This commit is contained in:
Executable
+9
@@ -0,0 +1,9 @@
|
||||
#!/bin/sh
|
||||
|
||||
if test "x$TRUNNEL_PATH" != "x"; then
|
||||
PYTHONPATH="${TRUNNEL_PATH}:${PYTHONPATH}"
|
||||
export PYTHONPATH
|
||||
fi
|
||||
|
||||
python -m trunnel ./src/trunnel/*.trunnel
|
||||
|
||||
+9
-3
@@ -1,5 +1,6 @@
|
||||
|
||||
/* pwbox.c -- generated by trunnel. */
|
||||
/* pwbox.c -- generated by Trunnel v1.1-dev.
|
||||
* https://gitweb.torproject.org/trunnel.git
|
||||
*/
|
||||
#include <stdlib.h>
|
||||
#include "trunnel-impl.h"
|
||||
|
||||
@@ -303,12 +304,18 @@ pwbox_encoded_encode(uint8_t *output, size_t avail, const pwbox_encoded_t *obj)
|
||||
size_t written = 0;
|
||||
uint8_t *ptr = output;
|
||||
const char *msg;
|
||||
#ifdef TRUNNEL_CHECK_ENCODED_LEN
|
||||
const ssize_t encoded_len = pwbox_encoded_encoded_len(obj);
|
||||
#endif
|
||||
int enforce_avail = 0;
|
||||
const size_t avail_orig = avail;
|
||||
|
||||
if (NULL != (msg = pwbox_encoded_check(obj)))
|
||||
goto check_failed;
|
||||
|
||||
#ifdef TRUNNEL_CHECK_ENCODED_LEN
|
||||
trunnel_assert(encoded_len >= 0);
|
||||
#endif
|
||||
|
||||
/* Encode u32 fixedbytes0 IN [PWBOX0_CONST0] */
|
||||
trunnel_assert(written <= avail);
|
||||
@@ -383,7 +390,6 @@ pwbox_encoded_encode(uint8_t *output, size_t avail, const pwbox_encoded_t *obj)
|
||||
goto check_failed;
|
||||
#ifdef TRUNNEL_CHECK_ENCODED_LEN
|
||||
{
|
||||
ssize_t encoded_len = pwbox_encoded_encoded_len(obj);
|
||||
trunnel_assert(encoded_len >= 0);
|
||||
trunnel_assert((size_t)encoded_len == written);
|
||||
}
|
||||
|
||||
+3
-2
@@ -1,5 +1,6 @@
|
||||
|
||||
/* pwbox.h -- generated by trunnel. */
|
||||
/* pwbox.h -- generated by by Trunnel v1.1-dev.
|
||||
* https://gitweb.torproject.org/trunnel.git
|
||||
*/
|
||||
#ifndef TRUNNEL_PWBOX_H
|
||||
#define TRUNNEL_PWBOX_H
|
||||
|
||||
|
||||
Reference in New Issue
Block a user