Sean DuBois
0c8abd0bc3
Improve STUN/DTLS/SRTP demux, use example from RFC
2018-07-21 12:27:38 -07:00
Sean DuBois
ec5c743b55
Implement CookieEcho, respond with CookieAck
...
Peer now starts sending heartbeats, association is good!
2018-07-21 12:27:38 -07:00
Sean DuBois
e7ede14f5c
De-dupe some OpenSSL code, and make sure we free tlscfg
2018-07-21 12:27:38 -07:00
Sean DuBois
665fb76255
Fix gotestyourself import
2018-07-21 12:27:38 -07:00
John R. Bradley
6a406eedfb
Add comment to checkPacket
2018-07-21 12:27:38 -07:00
John R. Bradley
c0bef470a2
Fix initial receiver window, now receives a COOKIE-ECHO from chrome
2018-07-21 12:27:38 -07:00
John R. Bradley
4902443ea6
Bring back commented tests
2018-07-21 12:27:38 -07:00
John R. Bradley
a1874f912d
Pad out each chunk
2018-07-21 12:27:38 -07:00
John R. Bradley
22e98b0dfb
Refactor chunk marshal, fix many marshaling bugs
2018-07-21 12:27:38 -07:00
John R. Bradley
4fc7cfccec
Add unrecognized parameter
...
We need to also store the raw including header for easier access instead of
remarshaling every time
2018-07-21 12:27:38 -07:00
John R. Bradley
df7d786d85
Refactor param marshal to match other marshal methods
2018-07-21 12:27:38 -07:00
Sean DuBois
2d57c5856c
Implement Abort + ErrorCause handling
...
Add all the boilerplate for handling this implement
InvalidMandatoryParameter and UnrecognizedChunkType
2018-07-21 12:27:38 -07:00
John R. Bradley
0e43088e58
Add init ack sending, added cookie state
2018-07-21 12:27:38 -07:00
John R. Bradley
04f049fb4c
Add chunk intersect and a couple comments
2018-07-21 12:27:38 -07:00
John R. Bradley
4f3632fee2
Refactor param and add marshal methods to each param
2018-07-21 12:27:38 -07:00
Sean DuBois
5849e549a7
Implement Marshal for multiple structs, with some tests
...
* Add test for Packet marshal
* Implement Packet, ChunkHeader, ChunkInitAck
* Improve error messages, and de-dupe some comments
2018-07-21 12:27:38 -07:00
John R. Bradley
162b39ce4d
More changes getting ready for finishing up INIT
2018-07-21 12:27:38 -07:00
John R. Bradley
29dc3df8e2
WIP, Moved Init to common, added more pre-checks
2018-07-21 12:27:38 -07:00
Sean DuBois
c7da9212cd
Add comments to SCTP + start InitAck
2018-07-21 12:27:38 -07:00
Sean DuBois
51e669e1d8
Improve error handling and enums in SCTP
...
* Make sure errors in SCTP make it all the way back
* Move structs into files with proper names in SCTP
* Add String() for AssociationState enum
* Add callbacks to Association to that we can handle
DATA in the DataChannel package and send outbound SCTP
2018-07-21 12:27:38 -07:00
John R. Bradley
93fa676740
Add more association logic, RFC stuff
2018-07-21 12:27:38 -07:00
John R. Bradley
e8b58bf959
Add all params sent from init chunk
2018-07-21 12:27:38 -07:00
Sean DuBois
0c9565896e
Implement SCTP checksum
2018-07-21 12:27:38 -07:00
Sean DuBois
00a56d866c
Implement outbound DTLS
2018-07-21 12:27:38 -07:00
John R. Bradley
4a518b50fb
Move params to own directory
2018-07-21 12:27:38 -07:00
John R. Bradley
47971c37b8
Add rudimentary parameter parsing
2018-07-21 12:27:38 -07:00
Sean DuBois
f2b9791623
Implement SCTP Init chunk, and start InitAck
2018-07-21 12:27:38 -07:00
Sean DuBois
cca92b5dd7
Fix lint, vet and cyclo errors
2018-07-21 12:27:38 -07:00
Sean DuBois
766b1c2d3f
Add early return to SCTP chunk parsing when invalid length
2018-07-21 12:27:38 -07:00
Sean DuBois
5ec9022685
SCTP Packet+Chunk Unmarshalling with tests
2018-07-21 12:27:38 -07:00
Sean DuBois
f7801d4afc
Implement structs for SCTP Packet and SCTP chunks
2018-07-21 12:27:38 -07:00
Sean DuBois
b69b185bd5
Initial commit
...
* DTLS packets are decrypt
* Sending DTLS packets has prototype, but has not been implemented
* We print the SCTP packets, but they aren't parsed yet
2018-07-21 12:27:38 -07:00
backkem
ab6910899c
api: support a custom media engine
2018-07-16 14:20:18 -07:00
backkem
f7c5ecd57f
api: fix typos
2018-07-16 14:20:18 -07:00
backkem
1bdd1af406
mediaengine: cleanup
2018-07-16 14:20:18 -07:00
backkem
7f682d2d2e
api: match WebRTC api more closely
2018-07-16 14:20:18 -07:00
Sean DuBois
2564609560
Disable STUN in examples temporarily
...
When we have multiple candidates that resolve we need to share DTLS
state across them
2018-07-14 13:26:01 -07:00
Sean DuBois
f440fc32d4
Finish STUN implementation
...
* Do not increment component id (this is used for marking RTP/RTCP)
* Add STUN to all examples so that they work out of the box
* Cast Addr from STUN client to UdpAddr instead of parsing
2018-07-11 21:58:49 -07:00
Raphael Randschau
8ed90c4fb0
listen on correct port
...
we need to listen on the local port of the STUN client, not the remote
one as those might be different
2018-07-11 21:58:49 -07:00
Raphael Randschau
e3269e606f
add remote description to STUN example
2018-07-11 21:58:49 -07:00
Raphael Randschau
791438e3cc
implement STUN support
2018-07-11 21:58:49 -07:00
Sean DuBois
dd0c3da122
Revert jsfiddle links with getUserMedia
...
AudioCapture and VideoCapture is blocked by jsfiddle when using this
feature. Need to debug+fix
2018-07-07 11:41:56 -07:00
Sean DuBois
76a07068c9
Use HTTPS for jsfiddle examples
2018-07-07 11:32:58 -07:00
Sean DuBois
7aa47c7d99
Add empty css files to jsfiddle demos
2018-07-07 11:32:58 -07:00
Sean DuBois
074e3391bf
Move JSfiddle snippets to git
...
jsfiddle provides a way to create snippets from Github via a URL. This
way we can still provide easy demos, but get all the nice things from
having them in Git
Closes #32
2018-07-07 11:32:58 -07:00
Raphael Randschau
98ea0b791e
fix warnings in examples
2018-07-06 15:23:40 -07:00
Raphael Randschau
4f6983307f
update examples with new constructor
2018-07-06 15:23:40 -07:00
Raphael Randschau
55c5aedb93
guard against missing RTCConfiguration
...
while the RTCConfiguration object is optional we need to ensure we don't
get panics due to nil's.
2018-07-06 15:23:40 -07:00
Raphael Randschau
5bec5cf115
extract RTCConfiguration into separate file
2018-07-06 15:23:40 -07:00
Raphael Randschau
2d003f539b
rename iceUsername and icePassword
2018-07-06 15:23:40 -07:00