Module: HTTP2
- Defined in:
- lib/http/2/header/huffman_statemachine.rb,
lib/http/2.rb,
lib/http/2/error.rb,
lib/http/2/base64.rb,
lib/http/2/client.rb,
lib/http/2/framer.rb,
lib/http/2/header.rb,
lib/http/2/server.rb,
lib/http/2/stream.rb,
lib/http/2/emitter.rb,
lib/http/2/version.rb,
lib/http/2/settings.rb,
lib/http/2/connection.rb,
lib/http/2/extensions.rb,
lib/http/2/flow_buffer.rb,
lib/http/2/header/huffman.rb,
lib/http/2/header/compressor.rb,
lib/http/2/header/decompressor.rb,
lib/http/2/header/encoding_context.rb,
sig/2.rbs,
sig/error.rbs,
sig/client.rbs,
sig/framer.rbs,
sig/header.rbs,
sig/server.rbs,
sig/stream.rbs,
sig/emitter.rbs,
sig/connection.rbs,
sig/extensions.rbs,
sig/flow_buffer.rbs,
sig/frame_buffer.rbs,
sig/header/huffman.rbs,
sig/header/compressor.rbs,
sig/header/decompressor.rbs,
sig/header/encoding_context.rbs
Overview
The following task generates this file. rake generate_huffman_table
Defined Under Namespace
Modules: Base64, BufferUtils, Emitter, Error, FlowBuffer, Header, PackingExtensions Classes: Client, Connection, FrameBuffer, Framer, Server, Settings, Stream
Constant Summary collapse
- EMPTY =
[].freeze
- END_STREAM =
Frame flags
ACK = 0b0001
- RESERVED =
1
0b0010- END_HEADERS =
2
0b0100- PADDED =
4
0b1000- PRIORITY =
8
0b0010_0000- VERSION =
"1.2.2"- SPEC_DEFAULT_CONNECTION_SETTINGS =
Default values for SETTINGS frame, as defined by the spec.
{ settings_header_table_size: 4096, settings_enable_push: 1, # enabled for servers settings_max_concurrent_streams: Framer::MAX_STREAM_ID, # unlimited settings_initial_window_size: 65_535, settings_max_frame_size: 16_384, settings_max_header_list_size: (2 << 30) - 1 # unlimited }.freeze
- DEFAULT_FLOW_WINDOW =
Default connection and stream flow control window (64KB).
65_535- DEFAULT_HEADER_SIZE =
Default header table size
4096- DEFAULT_MAX_CONCURRENT_STREAMS =
Default stream_limit
100- DEFAULT_CONNECTION_SETTINGS =
{ settings_header_table_size: 4096, settings_enable_push: 1, # enabled for servers settings_max_concurrent_streams: 100, settings_initial_window_size: 65_535, settings_max_frame_size: 16_384, settings_max_header_list_size: (2 << 30) - 1 # unlimited }.freeze
- DEFAULT_WEIGHT =
Default stream priority (lower values are higher priority).
16- CONNECTION_PREFACE_MAGIC =
Default connection "fast-fail" preamble string as defined by the spec.
"PRI * HTTP/2.0\r\n\r\nSM\r\n\r\n"- REQUEST_MANDATORY_HEADERS =
%w[:scheme :method :authority :path].freeze
- RESPONSE_MANDATORY_HEADERS =
%w[:status].freeze
- CONNECTION_FRAME_TYPES =
%i[settings ping goaway].freeze
- STREAM_OPEN_STATES =
%i[open half_closed_local].freeze
- ACK =
Instance Method Summary collapse
Instance Method Details
#urlsafe_decode64(str) ⇒ Object
35 36 37 38 39 40 41 42 43 |
# File 'lib/http/2/base64.rb', line 35 def urlsafe_decode64(str) if !str.end_with?("=") && str.length % 4 != 0 str = str.ljust((str.length + 3) & ~3, "=") str.tr!("-_", "+/") else str = str.tr("-_", "+/") end strict_decode64(str) end |