2. About me
• Braga
• MSc in Information Security (FCUL)
• Researcher@LaSIGE
• Motorcycles
• MSc Thesis
• RaptorQ implementation
• Breaking & Securing RQ
3. What you should take from this talk?
Theory:
• What are fountain codes?
• What properties they have?
• How can they be used?
You should think about:
• Where can I use them?
• How can my applications benefit from them?
• New ideas that work with this mindset
4.
5. FEC - Forward Error Correction
• Used to recover from errors occurred during transmission
• Sender encodes the message in a redundant way
• using an error-correcting code (ECC)
• Redundancy allows the receiver to detect errors
• and often to correct these errors without retransmission
• Corrects errors without a reverse channel to request
retransmission of data
• but at the cost of a fixed, higher forward channel bandwidth
• Usually applied in situations where retransmissions are
costly or impossible (e.g., multicast)
• Added to mass storage devices to enable recovery of
corrupted data (e.g., RAID)
6. Erasure codes
• Error correcting code
• Transforms a message of k symbols into a longer
message with n symbols
• The original message can be recovered from a
subset (k’) of the n symbols
• (Code rate) r = k/n proportion of the data-stream that is useful
• (Reception efficiency) k’/k
7. Fountain codes
• Rateless erasure code
• Endless supply of encoded symbols
• Recover original data with any K encoded symbols (with
high probability)
DigitalK
Receiver
(bucket)
Fountain
8. Use case: point-to-multipoint
• For a large number of receivers TCP does not
scale
• every receiver requires a separate data stream
• sender needs to keep track of what arrives at each
receiver
• UDP can be used
• scales effortlessly
• best effort: loss rate ↑ ⇒ degraded experience
• Difficult to provide a scalable broadcast
service on the Internet
• it would be interesting to have reliability whilst
retaining UDP’s efficiency
S
R2
R1
R4 R3
9. LT code (the first fountain code!)
• Based on two random generators
• One generates how many XORs should be made
• The other generates (the IDs of) which symbols will be XORed
• 5%-10% extra symbols are usually needed
S : source symbol E : encoding symbol (+ is the XOR operation)
E0 = S2 + S4 + S5 E1 = S0 + S1 + S2 E2 = S0 + S3 E3 = S2
E4 = S0 + S5 E5 = S2 + S5 E6 = S1 + S3 + S4 + S5
S0 S5S4S3S2S1
E0 E1 E2 E3 E4 E5 E6
11. HOW CAN WE USE THIS!?!?
Data
Partition into
Source Blocks
Source block i
RaptorQ
Decoder
Source block i
Data
Reconstruct
the data
Put in packets &
transmit through
the network
Received Symbols ( ≥ K)
Some packets are lost in the
network
RaptorQ Encoder
Source Symbols (K)
Repair
Generator
Repair Symbols (R)
Encoding Symbols
Can be used as
overhead (extra
symbols)
SENDER RECEIVER
14. Where to now?
• José Lopes, “Communication with RaptorQ Erasure Codes
in Malicious Environments”, MSc thesis
• José Lopes and Nuno Neves, “Stopping a Rapid Tornado
with a Puff” (soon to be IEEE S&P)
• The OpenRQ Library (www.lasige.di.fc.ul.pt/openrq)
• Amin Shokrollahi, "Raptor codes”, IEEE Transactions on
Information Theory 52.6 (2006): 2551-2567.
• Amin Shokrollahi and Michael Luby, “Raptor Codes”
Now Publishers Inc 2011
• IETF RFC6330