Comments (6)
If we are to go with adaptive record sizing, that resizing decision has to be driven by tcp cwnd size ultimately. One idea would be to start small and then after transmitting x bytes of data, go big. Then downsize after y seconds of inactivity.
from s2n-tls.
There's something similar for Nginx which you could use as template:
http://forum.nginx.org/read.php?29,258662,259191#msg-259191
from s2n-tls.
Related ATS bug & discussion: https://issues.apache.org/jira/browse/TS-2503
from s2n-tls.
First pass at dynamic record sizing:
venkat1109@70498df
venkat1109@eac8c3d
There are a couple of things that I don't like about this change:
(1) Re-allocation / resizing of conn.out stuffer whenever the record size changes.
What do we do when re-allocation fails because of mlock() or madvise() ? Do we really want to bail the connection ? If so, how do we propagate the error to the caller ?
(2) Calls to s2n_timer_reset() inside of s2n_send()
Thoughts / suggestions ?
from s2n-tls.
Hi:
I am going to implement a simper logic to increase record size. here is my proposal:
Define:
outgoing_rec_threshold: the number of bytes to send before changing the record size.
outgoing_rec_timeout (in seconds). If this value > 0 then dynamic TLS record sizes feature is enabled. Otherwise, the feature is disabled (default).
Logic:
increase record size (phase 1):
Each connection starts with records of the min (S2N_SMALL_FRAGMENT_LENGTH, max_outgoing_fragment_length). if S2N_SMALL_FRAGMENT_LENGTH < max_outgoing_fragment_length, after sending outgoing_rec_threshold bytes the record size is increased to max_outgoing_fragment_length.
reset record size (phase 2):
if the connection idles for longer than outgoing_rec_timeout then the TLS record size is reduced to S2N_SMALL_FRAGMENT_LENGTH and the logic above is repeated.
from s2n-tls.
Dynamic record size support was added in 8b8cd07
from s2n-tls.
Related Issues (20)
- Integ test bloat
- Make S2N_CERT_AUTH_OPTIONAL the default for clients
- Support loading DER-encoded certificates and private keys
- consider adding a default negotiate timeout
- enforce result checking for s2n_stuffer methods
- Unpin dependencies after bumping MSRV beyond 1.70
- add visible debugging information for CI runs
- old libfuzzer used in CI
- old cppcheck used in CI
- Add schannel to integration tests HOT 1
- docs: Rust bindings need an explanation for Send/Sync impls HOT 1
- Add rustls to integration tests HOT 3
- test: SSLv2 integ test
- s2n_tls13_cert_verify_test doesn't run all cases HOT 1
- certificate_signature_preferences field contains unnecessary information HOT 2
- UBSAN triggers on `is_available` getting passed an incorrect function type HOT 5
- version 1.4.5: s2n_shutdown_test fail HOT 2
- clang format all .c and .h files
- make it easier to evaluate the impacts of changing security policies
- Clarify return values of IO APIs in the API documentation
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from s2n-tls.