Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RFE: Allow all HTTP_FIELD_xxx values to go beyond HTTP_MAX_VALUE bytes, support coalescing of all fields #5216

Closed
michaelrsweet opened this issue Jan 6, 2018 · 1 comment
Assignees
Labels
enhancement New feature or request priority-low
Milestone

Comments

@michaelrsweet
Copy link
Collaborator

While investigating IndieAuth's OAuth extensions, specifically the profile URL stuff, I determined that the current libcups limit of 255 bytes for header field values affects the Link: HTTP header (HTTP_FIELD_LINK), and that it needs the same multiple header support as some of the other fields.

Consider implementing a full shadow array of char *'s so that small values use the legacy char arrays and longer values use the allocated ones.

Also support coalescing of header values into comma-delimited ones, per the HTTP spec.

@michaelrsweet michaelrsweet self-assigned this Jan 6, 2018
@michaelrsweet michaelrsweet added enhancement New feature or request priority-low labels Jan 6, 2018
@michaelrsweet michaelrsweet added this to the CUPS 2.3.x milestone Jan 6, 2018
michaelrsweet pushed a commit that referenced this issue Jan 11, 2018
…AX_VALUE

bytes (Issue #5216)

cups/http-private.h:
- Move all char * shadow variables to new fields array, rename old fields array
  to _fields (binary compatibility).

cups/http.c:
- Add new http_add_field that can handle appending values and allocating or
  clearing strings as needed.
- Update httpSetField to use http_add_field.
- Update _httpUpdate to use http_add_field instead of httpSetField.

cups/request.c:
- Fix checks for header fields.

cups/tls-*.c:
- Fix checks for Host header field.
@michaelrsweet
Copy link
Collaborator Author

[master 378eeed] Update HTTP implementation to support field values larger than HTTP_MAX_VALUE bytes (Issue #5216)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request priority-low
Projects
None yet
Development

No branches or pull requests

1 participant