Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
    • Contribute to GitLab
  • Sign in
T
Tor
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 1,066
    • Issues 1,066
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
  • Merge Requests 17
    • Merge Requests 17
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
  • Operations
    • Operations
    • Incidents
    • Environments
  • Analytics
    • Analytics
    • CI / CD
    • Repository
    • Value Stream
  • Members
    • Members
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
Collapse sidebar

GitLab is used only for code review, issue tracking and project management. Canonical locations for source code are still https://gitweb.torproject.org/ https://git.torproject.org/ and git-rw.torproject.org.

  • The Tor Project
  • Core
  • Tor
  • Issues
  • #31682

Closed
Open
Opened Sep 10, 2019 by teor@teor

CID 1453653: Integer handling (NEGATIVE_RETURNS) in build_establish_intro_dos_extension()

trn_cell_extension_dos_encoded_len() returns ssize_t, but trn_cell_extension_field_setlen_field() takes size_t. This looks like a bug on legacy/trac#30924 (moved), copying sponsor fields across.

/src/feature/hs/hs_cell.c: 532 in build_establish_intro_dos_extension()
528       /* Set the field with the encoded DoS extension. */
529       dos_ext_encoded_len = trn_cell_extension_dos_encoded_len(dos_ext);
530       /* Set length field and the field array size length. */
531       trn_cell_extension_field_set_field_len(field, dos_ext_encoded_len);
   CID 1453653:  Integer handling issues  (NEGATIVE_RETURNS)
   "dos_ext_encoded_len" is passed to a parameter that cannot be negative.
532       trn_cell_extension_field_setlen_field(field, dos_ext_encoded_len);
533       /* Encode the DoS extension into the cell extension field. */
534       field_array = trn_cell_extension_field_getarray_field(field);
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information
Assignee
Assign to
Tor: 0.4.2.x-final
Milestone
Tor: 0.4.2.x-final
Assign milestone
Time tracking
None
Due date
None
Reference: tpo/core/tor#31682