Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
T
Tor
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Benjamin J. Thompson
Tor
Commits
e459f6ee
Commit
e459f6ee
authored
19 years ago
by
Peter Palfrader
Browse files
Options
Downloads
Patches
Plain Diff
Add directory format fix to debian's 0.1.1.8-alpha-1
svn:r5232
parent
c48ccf9d
No related branches found
Branches containing commit
Tags
debian-version-0.1.1.8-alpha-1
Tags containing commit
No related merge requests found
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
debian/changelog
+5
-1
5 additions, 1 deletion
debian/changelog
debian/patches/00list
+1
-0
1 addition, 0 deletions
debian/patches/00list
debian/patches/08_add_newlines_between_serverdescriptors.dpatch
+66
-0
66 additions, 0 deletions
.../patches/08_add_newlines_between_serverdescriptors.dpatch
with
72 additions
and
1 deletion
debian/changelog
+
5
−
1
View file @
e459f6ee
tor (0.1.1.8-alpha-1) experimental; urgency=low
* New upstream version.
* Add patch from CVS to
"Insert a newline between all router descriptors when generating (old
style) signed directories, in case somebody was counting on that".
r1.247 of dirserv.c, <20051008060243.85F41140808C@moria.seul.org>
-- Peter Palfrader <weasel@debian.org> Sat, 8 Oct 2005
0
0:2
6:2
9 +0200
-- Peter Palfrader <weasel@debian.org> Sat, 8 Oct 2005
2
0:2
4:3
9 +0200
tor (0.1.1.7-alpha-1) experimental; urgency=low
...
...
This diff is collapsed.
Click to expand it.
debian/patches/00list
+
1
−
0
View file @
e459f6ee
...
...
@@ -2,3 +2,4 @@
03_tor_manpage_in_section_8.dpatch
06_add_compile_time_defaults.dpatch
07_log_to_file_by_default.dpatch
08_add_newlines_between_serverdescriptors
This diff is collapsed.
Click to expand it.
debian/patches/08_add_newlines_between_serverdescriptors.dpatch
0 → 100755
+
66
−
0
View file @
e459f6ee
#! /bin/sh -e
## 07_log_to_file_by_default.dpatch by <weasel@debian.org>
##
## All lines beginning with `## DP:' are a description of the patch.
## DP: No description.
if [ $# -lt 1 ]; then
echo "`basename $0`: script expects -patch|-unpatch as argument" >&2
exit 1
fi
[ -f debian/patches/00patch-opts ] && . debian/patches/00patch-opts
patch_opts="${patch_opts:--f --no-backup-if-mismatch} ${2:+-d $2}"
case "$1" in
-patch) patch -p1 ${patch_opts} < $0;;
-unpatch) patch -R -p1 ${patch_opts} < $0;;
*)
echo "`basename $0`: script expects -patch|-unpatch as argument" >&2
exit 1;;
esac
exit 0
@DPATCH@
diff -u -d -r1.246 -r1.247
--- tor-0.1.1.9/src/or/dirserv.c 6 Oct 2005 04:33:40 -0000 1.246
+++ /tmp/dpep.YwfNhI/tor-0.1.1.9/src/or/dirserv.c 8 Oct 2005 06:02:41 -0000 1.247
@@ -731,6 +731,7 @@
dirserv_dump_directory_to_string(char **dir_out,
crypto_pk_env_t *private_key)
{
+ char *cp;
char *router_status;
char *identity_pkey; /* Identity key, DER64-encoded. */
char *recommended_versions;
@@ -765,7 +766,7 @@
buf_len = 2048+strlen(recommended_versions)+
strlen(router_status);
SMARTLIST_FOREACH(descriptor_list, routerinfo_t *, ri,
- buf_len += ri->signed_descriptor_len);
+ buf_len += ri->signed_descriptor_len+1);
buf = tor_malloc(buf_len);
/* We'll be comparing against buf_len throughout the rest of the
function, though strictly speaking we shouldn't be able to exceed
@@ -785,9 +786,17 @@
tor_free(router_status);
tor_free(identity_pkey);
+ cp = buf + strlen(buf);
SMARTLIST_FOREACH(descriptor_list, routerinfo_t *, ri,
- if (strlcat(buf, ri->signed_descriptor, buf_len) >= buf_len)
- goto truncated);
+ {
+ if (cp+ri->signed_descriptor_len+1 >= buf+buf_len)
+ goto truncated;
+ memcpy(cp, ri->signed_descriptor, ri->signed_descriptor_len);
+ cp += ri->signed_descriptor_len;
+ *cp++ = '\n'; /* add an extra newline in case somebody was depending on
+ * it. */
+ });
+ *cp = '\0';
/* These multiple strlcat calls are inefficient, but dwarfed by the RSA
signature.
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment