Opened 13 years ago

Last modified 7 years ago

#291 closed defect (Fixed)

NEWDESC events sometimes include truncated IDs

Reported by: edmanm Owned by:
Priority: Low Milestone:
Component: Core Tor/Tor Version:
Severity: Keywords:
Cc: edmanm Actual Points:
Parent ID: Points:
Reviewer: Sponsor:

Description

[edmanm@adrastea:~]$ telnet localhost 9051
Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
authenticate
250 OK
getinfo version
250-version=0.1.1.19-rc
250 OK
setevents newdesc
250 OK
650 NEWDESC 06EC24D4E463F23D6EC646F88FDD746521D9442D 0C43A8E643548F7DE6173178FD0B7D8A3308036F 1405C41C94242B30F46E9396EC8A8D3A6C6C9240
191D0CEF97EB82CAD0EBBAE67487B1FF713DFEE4 1BE3590BA6AB203B9921DB428FF1F61052504C4F 1C2E6B96DB69E38AF3F372A3059A3525D8F5A8C5
1D27E66D08594CD5561EABCABF9C54259A67BEF8 2569E6088637529C7F4F1A9531C29043C935C47F 2572F3F0DE49357B679162CD62778BD148977E24
26FE4DF3CD72297FCFA4D976F20C594388665F56 28A021DB08FEC1B356076BCCBA9125D19509C32F 2AF395C600C9BBACEC70F7A763A293ABC3DB9253
2B4DE759C72F111D4EB5864D3F2CCF4AB38994F5 2CB091B4167183B0C579026EB0F149C292EA3912 2E9D2C58ED6B2A82CE15949E7A8AD2E20BECA3AB
337E599367550A6BF3D9785AAB1FABAFEB1B9B0B 353E27DFBF41251058D7EE58E674B95D922A83B1 37EFBEE64C465DB3A9025DDC7FF180ACBFE82D1E
3831B366B72E7F8A1927F952FFD88FDBC1DA4F2B 3871317A7416C3EE3D63F1BB0C3D1F35F9591E34 389C064C4379FCEE11181F2D85E6FB501D9A74E8
3FE5744E21A09CD7BBB17A1F2F393A3F2F8A1737 45C93541FA68D0FDD2D5405C3E991CD863098580 46F255C4D368596A1548D7A9B361C3580319D920
470F4E6B8D06942E629B4F80D
650 NEWDESC BAD47A6FB8E207F51FD01B5589181F750485D0A3 BC33B48B5E03DD7EDC61DAF7CB987FFFE5F4271E BD7E124EC3CB6B558EECDF84121B21E0373F4C26
C76815FA912A6B2954B70DA4FF033902CC4F0650 C9D329631642E01BAB39671BBD33EEEA06A2E6EC CA75FA9902A200EE5C2B41EA11055F6BD6624457
CDDD404B4A61AA21EA0E637E69DEE91AAA52DA70 CE52820C6795A5AB6528BEC853EEE71A65EF26E8 D35E1FFFB10EF66F6DFBE2EB977667BA8BD8BBB5
D5F2C65F4131A1468D5B67A8838A9B7ED8C049E2 D683E7E5E4468D67659FAE14EB3E0216786DC8E9 D754E6D7E34D0CAA8428422A022CA697C3397981
D8BE5A425E616679A0966A2CCCBE30183019352D DA42FA10174D0482A801782E4DAEAC1FB6987933 DD1C53F230DDD06726D541B23243066098629C14
E6A4BD6150D0385C60BFA96AA7E3E9CBF748B0DF E710B7B1BCC65FECE5BA345CEC8B81BEA216318F EA40EDEB4E9100FA68B020AD9600BEF9939B0CA8
EACB6330CD96AB696523C88D10A3FEBE5FFC3841 EB339BFFCABD2DE0DF7ADCD0F20FEB725827E506 EBB1D8477C731F46FFC8934E463465D4EBD4EDEC
EBE830DCE9A24038DD8A777FBB9C66792CF2B9DF ED4CEEB89E3A8E74E7D9FEF80DD8AC99C74C0C88 EF558AFB169532FC391B885FEEB5E7FA49B43850
F8C0CDB892C5A2E6CFB041018
650 NEWDESC 536C45AD3FCAFA88D70B830B9B323284CDE013AA 53D366DA48B8C2749340FE969FEF5B2DD073AF69 55BC79A4610212F56F475F4ECD667DBA9AB5A433
55F6F11ECDD5CAC793D5058ECAAAF5CDED2BD571 59CBA17C53F0BD79D6106B70A769BCA23A8C3EAC 5D02C99CCF841495A0ACBF917A0A750B9646DB8D
5F8AB19F5CB30B70A9530A426846548F2401796F 6C1854DCD38E6BD3A017C9AB1A45B7FA465E64D9 6CE2E5224D203AD9369491BCF2FD192C6D8F2E48
7419139C78D79C45419D5C83B8CCD3F461B53966 76D72D2B5E0523FCAB75A5EDD795E76B6C46B843 79AA2C6BFC01BFC9E5634793D0C3B505EB05CF3C
82BD1D9A6D41DF196DA37F9ABBCC66FFA494C39D 83731D55E300483F591C2CA3A896251E8714F96E 847B1F850344D7876491A54892F904934E4EB85D
86299223B175C4A2BF840869FEBC32C1E3AB8F24 8AB95DC79BC521B00E574F426DCB5441560D13E4 8B6F5999A60F66A07D51BA0C7B9B1456E8F77310
8CCA8F718E687F2B38CAAECF114278ADE7ACC597 8E1A4260530F304B1F816C896F3231751BA8EA6D A4D468D135F2F83D6CACDC85975B562BDEF3A936
A648B345CEB029D0763BA86B26DC97F6E44AD988 A6E8B6355A356056A9022AE7FCCB423C6FB3321D AA4019D85823518F09043F05E61EAE5E52CA78B4
AF997E0B4AD21F248A8C27D19
650 NEWDESC 24AC6F92E1B28CCA697175C2E41C0B28797D3401 38845B60D6635E35F83C41C0AFBF2134C7F00FC5 C5300BF770746D7DD7E85AB908E1F5E56F677208
CE1B93A998DE00FD958B06D5A44A19A728291A7D

In the first three NEWDESC events, the last ID in each event message appears to be truncated. The last
ID in the fourth NEWDESC event is of normal length.

I poked around at this a bit and found this relevant looking bit of code in control.c:

607 #define SEND_CONTROL1_EVENT_BUFFERSIZE 1024
608 int r;
609 char buf[SEND_CONTROL1_EVENT_BUFFERSIZE]; /* XXXX Length */

Given that the truncated NEWDESC event messages above are 1022 bytes long (and then two bytes for a \r\n),
it appears that I ran into the XXXX above. :)

[Automatically added by flyspray2trac: Operating System: All]

Child Tickets

Change History (3)

comment:1 Changed 13 years ago by arma

Fixed in cvs and in the 0.1.1.x cvs branch. Let us know if it's not actually fixed!

comment:2 Changed 13 years ago by arma

flyspray2trac: bug closed.

comment:3 Changed 7 years ago by nickm

Component: Tor ClientTor
Note: See TracTickets for help on using tickets.