SlideShare una empresa de Scribd logo
1 de 56
Descargar para leer sin conexión
Introduction
                             OTR
                        Deniability
       Secure Function Evaluation
           Putting It All Together
                          The End




Secure Function Evaluation vs. Deniability
            In OTR and Similar Protocols


                           bruhns, greg

                         CONFidence 2012




                                      Secure Function Evaluation vs. Deniability
Introduction
                                      OTR
                                 Deniability
                Secure Function Evaluation
                    Putting It All Together
                                   The End


What and why?




     OTR is a popular cryptographic protocol.
     It features a number of properties, such as confidentiality,
     integrity and also deniability.
     We’re going to focus on the deniability aspect of the protocol.




                                               Secure Function Evaluation vs. Deniability
Introduction
                                          OTR
                                     Deniability
                    Secure Function Evaluation
                        Putting It All Together
                                       The End


TOC

 1   Introduction

 2   OTR

 3   Deniability

 4   Secure Function Evaluation

 5   Putting It All Together

 6   The End


                                                   Secure Function Evaluation vs. Deniability
Introduction
                            OTR
                       Deniability
      Secure Function Evaluation
          Putting It All Together
                         The End




OTR




                                     Secure Function Evaluation vs. Deniability
Introduction
                                      OTR
                                 Deniability
                Secure Function Evaluation
                    Putting It All Together
                                   The End


OTR



      Off-the-Record Messaging
      Cryptographic protocol for instant messaging
      Interesting properties
          Confidentiality
          Integrity
          Forward Secrecy
          Mutual authentication using SMP
          Deniability




                                               Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Security Properties
  General setting: Alice ↔ Eve ↔ Bob
  Confidentiality & Integrity
  Eve cannot decipher any of Bob’s or Alice’s messages. Neither can
  she modify any of those messages (without Alice or Bob noticing
  that).

  Forward Secrecy
  Suppose Alice looses her private key. Eve should not be able to
  decipher any messages that has already been sent in a prior
  conversation between Alice and Bob.

  Mutual authentication
  Alice and Bob can authenticate each other.
                                                Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Security Properties
  General setting: Alice ↔ Eve ↔ Bob
  Confidentiality & Integrity
  Eve cannot decipher any of Bob’s or Alice’s messages. Neither can
  she modify any of those messages (without Alice or Bob noticing
  that).

  Forward Secrecy
  Suppose Alice looses her private key. Eve should not be able to
  decipher any messages that has already been sent in a prior
  conversation between Alice and Bob.

  Mutual authentication
  Alice and Bob can authenticate each other.
                                                Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Security Properties
  General setting: Alice ↔ Eve ↔ Bob
  Confidentiality & Integrity
  Eve cannot decipher any of Bob’s or Alice’s messages. Neither can
  she modify any of those messages (without Alice or Bob noticing
  that).

  Forward Secrecy
  Suppose Alice looses her private key. Eve should not be able to
  decipher any messages that has already been sent in a prior
  conversation between Alice and Bob.

  Mutual authentication
  Alice and Bob can authenticate each other.
                                                Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Security Properties
  General setting: Alice ↔ Eve ↔ Bob
  Confidentiality & Integrity
  Eve cannot decipher any of Bob’s or Alice’s messages. Neither can
  she modify any of those messages (without Alice or Bob noticing
  that).

  Forward Secrecy
  Suppose Alice looses her private key. Eve should not be able to
  decipher any messages that has already been sent in a prior
  conversation between Alice and Bob.

  Mutual authentication
  Alice and Bob can authenticate each other.
                                                Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Security Properties


  General setting: Alice ↔ Eve ↔ Bob
  Deniability
  Both, Alice and Bob are hackers and talk about serious stuff (TM)
  using OTR. Now Alice turns evil and wants to backstab on Bob.
  Debiability means that Alice can not prove that Bob was really the
  author of any message he sent (yet, during the conversation Alice
  is still sure that she talks to Bob).




                                                Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Key Exchange & Message Crypto

  Simplified version of the protocol:
      Each party has an asymmetric key pair, which we’ll call
      master key
      Use Diffie-Hellman to establish a common set of encryption
      and authentication keys. Alice and Bob sign their
      Diffie-Hellman messages with their master keys.
      → Authentication and Forward Secrecy
      → Deniability (weak)
      Messages are encrypted (AES-CTR) and MACed (HMAC)
      using the symmtric keys that have been generated.
      → Confidentiality and integrity


                                                Secure Function Evaluation vs. Deniability
Introduction
                                     OTR
                                Deniability
               Secure Function Evaluation
                   Putting It All Together
                                  The End


Key Exchange & Message Crypto




     Each message contains a new DH key exchange proposal (also
     MACed of course). As soon as new keys have been
     established, the old MAC keys are made public.
     → Deniability (strong)




                                              Secure Function Evaluation vs. Deniability
Introduction
                                      OTR
                                 Deniability
                Secure Function Evaluation
                    Putting It All Together
                                   The End


Re-Keying


     Both parties frequently re-key the symmetric primitives.
     The re-keying procedure is significantly simpler than the initial
     key-exchange - we already have key material exchanged.
     General approach: Perform a DH key-exchange and use
     already established MAC keys to authenticate the
     communication.
     Advantage: We can publish the “old” MAC keys, as they are
     not longer used. We will not disclose our encryption keys,
     though!



                                               Secure Function Evaluation vs. Deniability
Introduction
                               OTR
                          Deniability
         Secure Function Evaluation
             Putting It All Together
                            The End




Deniability




                                        Secure Function Evaluation vs. Deniability
Introduction
                                        OTR
                                   Deniability
                  Secure Function Evaluation
                      Putting It All Together
                                     The End


Deniability
  How could Alice attack Bob’s deniability?
  +-------+ "I pwn3d XYZ", sig(..)    +-------+
  | Alice | <-----------------------> | Bob |
  +-------+                           +-------+
      ^
      | "Bob pwn3d XYZ, here’s a proof"   +-------+
      +---------------------------------> | Judge |
                                          +-------+


      Simple offline attack
      Bob will argue that Alice just made up the signature. She can do
      that, because OTR is deniable (more on that later).
      But Alice might try something else. . .
                                                 Secure Function Evaluation vs. Deniability
Introduction
                                        OTR
                                   Deniability
                  Secure Function Evaluation
                      Putting It All Together
                                     The End


Deniability
  How could Alice attack Bob’s deniability?
  +-------+ "I pwn3d XYZ", sig(..)    +-------+
  | Alice | <-----------------------> | Bob |
  +-------+              ^            +-------+
      ^                  |
      |                  +---- Sniff ------------+
      |                                          |
      | "See? Bob really said he pwn3d XYZ." +-------+
      +------------------------------------> | Judge |
                                             +-------+


      If the judge sniffs all traffic, he knows that Bob said. Alice can give
      him the encryption/MAC key and he can verify that.
      Hard to implement (especially if Alice/Bob use an anonymizer).
                                                 Secure Function Evaluation vs. Deniability
Introduction
                                        OTR
                                   Deniability
                  Secure Function Evaluation
                      Putting It All Together
                                     The End


Deniability
  How could Alice attack Bob’s deniability?
  +-------+           +-------+
  | Alice |<-+    +->| Bob |
  +-------+ |     | +-------+
             |    |
             v    v
            +-------+
            | Judge |
            +-------+


      Online attack: Alice forwards all traffic to the judge. Also won’t
      work: Bob will again argue that Alice faked the messages.
      Alice gives her master key to the judge, who will act as a proxy for
      Alice. He will read all messages, check integrity and authentication.
                                                 Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Deniability
  How could Alice attack Bob’s deniability?
  +-------+           +-------+
  | Alice |<-+    +->| Bob |
  +-------+ |     | +-------+
             |    |
             v    v
            +-------+
            | Judge |
            +-------+


      But now the judge can impersonate Alice and Alice doesn’t really
      trust the judge.
      What if there was a party that both, Alice and the judge, trust?

                                                Secure Function Evaluation vs. Deniability
Introduction
                                        OTR
                                   Deniability
                  Secure Function Evaluation
                      Putting It All Together
                                     The End


Deniability
  How could Alice attack Bob’s deniability?
  +-------+          +-------+
  | Alice |<-+    +->| Bob |
  +-------+ |     | +-------+
             |    |
             v    v
            +----------------+       +-------+
            | Alice’s Lawyer | <---> | Judge |
            +----------------+       +-------+


      Alice just gives her master keys to her lawyer.
      That looks pretty good. But Alice has some doubts. . .
          Does the judge really trust her lawyer?
          Worse: does she really trust her lawyer?
                                                 Secure Function Evaluation vs. Deniability
Introduction
                                        OTR
                                   Deniability
                  Secure Function Evaluation
                      Putting It All Together
                                     The End


Deniability
  How could Alice attack Bob’s deniability?
  +-------+          +-------+
  | Alice |<-+    +->| Bob |
  +-------+ |     | +-------+
             |    |
             v    v
            +----------------+       +-------+
            | Alice’s Lawyer | <---> | Judge |
            +----------------+       +-------+



      Lucky us: We’re all paranoid and there is no trusted third party.
      Alice’s goal: get rid of the lawyer!

                                                 Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Deniability
      There are actually two concepts of deniability: weak and
      strong deniability.
      Weak deniability: If one party discloses a message sent by the
      other party, the other party can claim that the message was
      actually faked by the disclosing party.
      Strong deniability: If a message gets disclosed, each party can
      claim that anybody could have faked that message.
      Weak deniability is pretty obvious: both parties are in
      possession of encryption and MAC keys, so there is no way to
      distinguish who actually sent a message.
      Attacks can be offline (observer not involved in the
      conversation) and online (observer is involved in the
      conversation).
                                                Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Strong Deniability

      That’s a bit harder. The main idea here is that after each
      re-keying, the old MAC keys are disclosed.
      In order to fake a message, we need to know two things: MAC
      key (is public) and encryption key. The encryption key is never
      disclosed to the public, because that would violate the
      confidentiality.
      But using the MAC key, we can create a fake re-keying event,
      so that encryption and MAC keys are generated, which we
      know.
      Now we can forge any message transcript.


                                                Secure Function Evaluation vs. Deniability
Introduction
                                     OTR
                                Deniability
               Secure Function Evaluation
                   Putting It All Together
                                  The End


What Does OTR Offer?

    OTR claims strong deniability.
    Deniability does not protect against someone who was evil
    right from the beginning! Such individuals could just share
    their master keys with any agency.
    If they are able to sniff your traffic, you’re screwed, too: they
    know, which messages you sent.
    But sniffing each and every network communication doesn’t
    scale well. Also, if your peer wasn’t evil right from the
    beginning, we cannot assume a trust relation between him and
    the attacker(s).


                                              Secure Function Evaluation vs. Deniability
Introduction
                              OTR
                         Deniability
        Secure Function Evaluation
            Putting It All Together
                           The End




Secure Function Evaluation




                                       Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Secure Function Evaluation



      Remember: Alice wanted to get rid of the lawyer. Doesn’t
      look like an easy task.
      But isn’t there any way to “emulate” that trusted third party?
      Crypto teaches us the surprising result: there actually is!
      It’s called Secure Function Evaluation (SFE).




                                                Secure Function Evaluation vs. Deniability
Introduction
                                      OTR
                                 Deniability
                Secure Function Evaluation
                    Putting It All Together
                                   The End


SFE



      A method for securely computing f (x, y ), where you know x,
      your peer knows y and neither you nor your peer want the
      other to learn x or y .
      Different approaches for implementing SFE
          (Partially) homomorphic cryptosystems
          Yao’s Garbled Circuits




                                               Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Oblivious Transfer


      Bob knows two values, x0 and x1 . He is willing to share
      exactly one with Alice.
      Alice wants one of those values, but doesn’t want to tell Bob,
      which one she wants.
      This problem is solved by oblivious transfer.
      There are many OT schemes out there, often based on
      trapdoor one-way functions. You can imagine those as
      instances of RSA, where f is the encryption function and f −1
      the decryption function (keys are fixed).



                                                Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


OT: Compact Version

  Bob knows x0 and x1 , Alice wants to receive one of them (xb with
  b ∈ {0, 1})
   A                                                                B
                                                                                      Pick f , f −1 , r0 , r1
                                          f ,r0 ,r1
                         ←− − − − − − − −
                         − − − − − − − −−
   Pick k
   compute z = f (k)
                                      z=f (k)⊕rb
                         −− − − − − − − −
                         − − − − − − − −→
                                                                               Compute candidates
                                                                           k0 = f −1 (z ⊕ r0 ) and k1
                           x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 )
                         ←−−−−−−−−
                          −−−−−−−−−

                                                      Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


OT: Compact Version

  Bob knows x0 and x1 , Alice wants to receive one of them (xb with
  b ∈ {0, 1})
   A                                                                B
                                                                                      Pick f , f −1 , r0 , r1
                                          f ,r0 ,r1
                         ←− − − − − − − −
                         − − − − − − − −−
   Pick k
   compute z = f (k)
                                      z=f (k)⊕rb
                         −− − − − − − − −
                         − − − − − − − −→
                                                                               Compute candidates
                                                                           k0 = f −1 (z ⊕ r0 ) and k1
                           x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 )
                         ←−−−−−−−−
                          −−−−−−−−−

                                                      Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


OT: Compact Version

  Bob knows x0 and x1 , Alice wants to receive one of them (xb with
  b ∈ {0, 1})
   A                                                                B
                                                                                      Pick f , f −1 , r0 , r1
                                          f ,r0 ,r1
                         ←− − − − − − − −
                         − − − − − − − −−
   Pick k
   compute z = f (k)
                                      z=f (k)⊕rb
                         −− − − − − − − −
                         − − − − − − − −→
                                                                               Compute candidates
                                                                           k0 = f −1 (z ⊕ r0 ) and k1
                           x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 )
                         ←−−−−−−−−
                          −−−−−−−−−

                                                      Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


OT: Compact Version

  Bob knows x0 and x1 , Alice wants to receive one of them (xb with
  b ∈ {0, 1})
   A                                                                B
                                                                                      Pick f , f −1 , r0 , r1
                                          f ,r0 ,r1
                         ←− − − − − − − −
                         − − − − − − − −−
   Pick k
   compute z = f (k)
                                      z=f (k)⊕rb
                         −− − − − − − − −
                         − − − − − − − −→
                                                                               Compute candidates
                                                                           k0 = f −1 (z ⊕ r0 ) and k1
                           x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 )
                         ←−−−−−−−−
                          −−−−−−−−−

                                                      Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


OT: Compact Version

  Bob knows x0 and x1 , Alice wants to receive one of them (xb with
  b ∈ {0, 1})
   A                                                                B
                                                                                      Pick f , f −1 , r0 , r1
                                          f ,r0 ,r1
                         ←− − − − − − − −
                         − − − − − − − −−
   Pick k
   compute z = f (k)
                                      z=f (k)⊕rb
                         −− − − − − − − −
                         − − − − − − − −→
                                                                               Compute candidates
                                                                           k0 = f −1 (z ⊕ r0 ) and k1
                           x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 )
                         ←−−−−−−−−
                          −−−−−−−−−

                                                      Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


OT: Compact Version

  Bob knows x0 and x1 , Alice wants to receive one of them (xb with
  b ∈ {0, 1})
   A                                                                B
                                                                                      Pick f , f −1 , r0 , r1
                                          f ,r0 ,r1
                         ←− − − − − − − −
                         − − − − − − − −−
   Pick k
   compute z = f (k)
                                      z=f (k)⊕rb
                         −− − − − − − − −
                         − − − − − − − −→
                                                                               Compute candidates
                                                                           k0 = f −1 (z ⊕ r0 ) and k1
                           x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 )
                         ←−−−−−−−−
                          −−−−−−−−−

                                                      Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


OT: Compact Version

  Bob knows x0 and x1 , Alice wants to receive one of them (xb with
  b ∈ {0, 1})
   A                                                                B
                                                                                      Pick f , f −1 , r0 , r1
                                          f ,r0 ,r1
                         ←− − − − − − − −
                         − − − − − − − −−
   Pick k
   compute z = f (k)
                                      z=f (k)⊕rb
                         −− − − − − − − −
                         − − − − − − − −→
                                                                               Compute candidates
                                                                           k0 = f −1 (z ⊕ r0 ) and k1
                           x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 )
                         ←−−−−−−−−
                          −−−−−−−−−

                                                      Secure Function Evaluation vs. Deniability
Introduction
                                      OTR
                                 Deniability
                Secure Function Evaluation
                    Putting It All Together
                                   The End


General OT Approach

     Bob choses f , f −1 (trapdoor one-way!) and sends f to Alice.
     Also, Bob picks two random values r0 and r1 , which he also
     sends to Alice.
     Alice wants to retrieve value xb from Bob. She first generates
     a random value k and computes z = f (k) ⊕ rb , which she
     sends to Bob.
     Bob computes k0 = f −1 (z ⊕ r0 ) and k1 = f −1 (z ⊕ r1 ). He can
     be sure that one of those k values is correct and the other one
     is junk. He computes x0 = x0 ⊕ k0 and x1 = x1 ⊕ k1 , which he
     sends to Alice.
     Alice receives x0 and x1 , but she can only decrypt one of
     them, because she only knows one k value.

                                               Secure Function Evaluation vs. Deniability
Introduction
                                     OTR
                                Deniability
               Secure Function Evaluation
                   Putting It All Together
                                  The End


GC SFE

    Evalution of boolean circuits (non-uniform computation)
    Functions can be modeled as circuits.
         That’s what happens when you program an FPGA.
    A circuit consists of gates and wires connecting those gates.
    Alice and Bob agree on a circuit. Alice “garbles” it and Bob
    evaluates the garbled circuit.
    Gates can be represented by their truth tables. For example:
        0 1
     0 0 0
     1 0 1


                                              Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Garbling a Gate

      Main idea: replace the binary inputs by (long) random strings.
      Instead of 1 or 0, we use keys like 350d5ea01e8a1f407cf or
      763581eb6cea7ec4b9a6e.
      Pick such random keys for each value of each wire (if we have
      inputs a and b, we’ll call the keys ka0 , ka1 , kb0 and kb1 ).
      Encrypt the truth table of the gate using the generated keys.
      Pick an encryption function E , decryption function D. Let D
      be built in such a way that it will complain if wrong keys are
      used (instead of just decrypting junk).
           0 1                   0               1
       0 0 0 → 0 Eka0 (Ekb0 (0)) Eka1 (Ekb0 (0))
       1 0 1           1 Eka0 (Ekb1 (0)) Eka1 (Ekb1 (1))

                                                Secure Function Evaluation vs. Deniability
Introduction
                                     OTR
                                Deniability
               Secure Function Evaluation
                   Putting It All Together
                                  The End


Garbling a Circuit
         Out                          When you have the input keys, just try to
          |                           decrypt all entries in a garbled gate until
       +------+                       one operation succeeds.
       | G1 |                         In1 , In2 and In4 are known (will cover that
       +------+                       later)
        |    |                        But where to get In3 from? Simple trick:
   In_3 |    |                        We put the key In3 into the garbled table
        |    |                        of G 2.
     +---+ In_4                                  0                   1
     |G2 |                             0 Eka0 (Ekb0 (In30 )) Eka1 (Ekb0 (In30 ))
     +---+                             1 Eka0 (Ekb1 (In30 )) Eka1 (Ekb1 (In31 ))
      |   
     In_1 In_2

                                              Secure Function Evaluation vs. Deniability
Introduction
                                      OTR
                                 Deniability
                Secure Function Evaluation
                    Putting It All Together
                                   The End


Evaluating a GC

     Where to get the input keys from?
     Alice can hard-code her inputs into the circuit when garbling
     it.
     Bob however doesn’t know the keys for his inputs.
     Bob could just ask Alice to give him the keys for his input
     values. But either he tells Alice what his input values are or
     Alice gives him the keys for all input values. Neither is
     acceptable.
     Solution: Oblivious transfer
     After Bob obliviously received his garbled input values, he
     evaluates the circuit, sends the result over to Alice and Alice
     de-garbles it.
                                               Secure Function Evaluation vs. Deniability
Introduction
                              OTR
                         Deniability
        Secure Function Evaluation
            Putting It All Together
                           The End




Putting It All Together




                                       Secure Function Evaluation vs. Deniability
Introduction
                                     OTR
                                Deniability
               Secure Function Evaluation
                   Putting It All Together
                                  The End


The Attack Idea



     SFE can be used to emulate a trusted third party.
     That is: Instead of letting a trusted third party compute some
     function for us, we can just do that ourselves and still have
     the same security properties.
     Use SFE to emulate a trusted third party: Somehow (TM)
     share our keys with that “third party”.




                                              Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Sharing is Caring

      We want to backstab our peer, therefore we collaborate with
      an observing party O (a.k.a. the judge or simply them).
      We keep our asymmetric master keys for ourselves.
      But every DH key exchange, we compute together with O.
      The resulting MAC keys are shared between O and us (i.e.
      neither O nor we know the keys, details later).
      The encryption keys are only known to us (otherwise, O could
      learn the plain text).
      To verify a message’s integrity, we collaborate with O. For
      signing a message, we also collaborate with O.


                                                Secure Function Evaluation vs. Deniability
Introduction
                                      OTR
                                 Deniability
                Secure Function Evaluation
                    Putting It All Together
                                   The End


Recap: Diffie-Hellman


     A and B publicly agree on a prime p and a generator g of a
     large cyclic subgroup of Zp .
     A picks a random a, computes g a . Same for B.
     A and B exchange g a and g b , but keep a and b secret.
     A computes k = (g b )a , B computes k = (g a )b . Both keys are
     the same k = g ab = g ba .
     An attacker cannot compute g ab from g a and g b alone
     (Diffie-Hellman problem).



                                               Secure Function Evaluation vs. Deniability
Introduction
                                     OTR
                                Deniability
               Secure Function Evaluation
                   Putting It All Together
                                  The End


The Attack Implementation

     Cooperative key-exchange: consider three parties A, B and O
     (Alice, Bob and the observing party). A and O cooperate.
      O                      A                      B
                  ga
          ←− − − − −
          − − − − −−
                 go
          −− − − − −
          − − − − −→
                                                       g ao
                                              −− − − − −
                                              − − − − −→
                                                        gb
                                              ←− − − − −
                                              − − − − −−
     B now knows g abo , but neither A not O can compute that
     value.
     Proof idea: A knows g b , g o and a. Computing g oab ↔
     computing g bo , equivalent to the Diffie-Hellman problem.

                                               Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


The Attack Implementation

     No SFE up to here!
     A and O both know g b . With their private exponents, A and
     O can compute g abo . But A and O don’t want to share a and
     o.
     From g abo , A and B can compute the encryption and MAC
     keys (those are generated by hasing g abo in various ways).
     The function that A and O want to compute is
     f (a, b) = (kE , kM ) = (HASHE (((g b )a )o ), HASHM (((g b )a )o )).
     Inputs of the function are the private exponents a and o.
     The circuit for that is rather big. . .


                                                Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Cleanup


     But now O knows the MAC key and could impersonate A and
     B. . .
     Fix: A has to get kE and A, O have to share kM !
          Easily possible by using a circuit that blinds some of its outputs
          with a key only known to one party: The circuit takes an
          additional input x and instead of kM it really computes kM ⊕ x.
          A will know kx := kM ⊕ x and O will know x.
     For every MAC computation, A and O will jointly compute
     f (kx , x, m) = HMAC (m, kx ⊕ x).



                                                Secure Function Evaluation vs. Deniability
Introduction
                                         OTR
                                    Deniability
                   Secure Function Evaluation
                       Putting It All Together
                                      The End


The Big Picture: Key Exchange
   O                                              A                                                B
                      go
       −− − − − − − − −
       − − − − − − − −→
                      ga
       ←− − − − − − − −
       − − − − − − − −−
                                                                           g ao
                                                         −−−−−−−−−
                                                         −−−−−−−−→
                                                                            gb
                                                          ←− − − − − − − −
                                                           − − − − − − − −−
                    f ,r0 ,r1
       ←− − − − − − − −
       − − − − − − − −−
                z=f (k)⊕rb
       −− − − − − − − −
       − − − − − − − −→
       x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 )
       ←−−−−−−−−
        −−−−−−−−−
            .
            .
            .
                       C
       ←−−−−−−−−
        −−−−−−−−
            eval(C )=kE ,kM ⊕x
       −− − − − − − − −
       − − − − − − − −→
                                                      Secure Function Evaluation vs. Deniability
Introduction
                                         OTR
                                    Deniability
                   Secure Function Evaluation
                       Putting It All Together
                                      The End


The Big Picture: Message Exchange


   O                                              A                                            B
                                                              E (m),HMAC (E (m))
                                                        ←− − − − − − − −
                                                        − − − − − − − −−
                   C ,f ,r0 ,r1
         ←−−−−−−−
          −−−−−−−
                 z=f (k)⊕rb
        −− − − − − − −→
        −−−−−−−−
        x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 )
       ←−−−−−−−−
        −−−−−−−−−
            .
            .
            .
          eval(C )=HMAC (E (m))
       −− − − − − − − − −
       − − − − − − − − −→




                                                  Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Security Properties of Our Scheme



      O will never see any plain text, so confidentiality stays.
      Without our help, O cannot sign or verify any message, so
      integrity also stays intact.
      Forward secrecy also remains OK, because O won’t learn any
      decryption keys anyway.




                                                Secure Function Evaluation vs. Deniability
Introduction
                                       OTR
                                  Deniability
                 Secure Function Evaluation
                     Putting It All Together
                                    The End


Security Properties of Our Scheme


      But deniability is gone: As we need the help of O to verify the
      messages of our peer, O learns about the integrity of the
      messages at the same time as we do.
      Messages that are created afterwards will be rejected by O,
      just because O has not seen those during the conversation.
      Even worse: We can selectively disclose any message content
      to O, just by telling O the decryption key for that particular
      message!
      This scheme can be extended to other protocols as well!



                                                Secure Function Evaluation vs. Deniability
Introduction
                                      OTR
                                 Deniability
                Secure Function Evaluation
                    Putting It All Together
                                   The End


What’s the Benefit of Our Scenario?



     No trust relationship with O is required (on no side).
     O doesn’t have to sniff anything.
     You don’t have to disclose everything you or your peer said.
     No “evil” intentions required.
     People might use it as a defense: “just to be sure.. if my peer
     turns evil at some point in time then I’ll disclose everything he
     said!”




                                               Secure Function Evaluation vs. Deniability
Introduction
                                      OTR
                                 Deniability
                Secure Function Evaluation
                    Putting It All Together
                                   The End


Closing remarks


      “So who is that obverving party?”
          They might be the NSA or anybody else.
          Probably the adversary you’re most afraid of.
      “Yeah, but you know what: they still cannot prove anything to
      (yet) another party. And in my country, you actually need to
      prove stuff in court!!1”
          Might be (are you sure?)
          But what if they are the judges / the jury?
      Cooperating “just to be safe” → prisoners dilemma



                                               Secure Function Evaluation vs. Deniability
Introduction
                                      OTR
                                 Deniability
                Secure Function Evaluation
                    Putting It All Together
                                   The End


Implementation Considerations

     A real-world implementation would be more complicated
     (OTR has some restrictions that we left out) but can be done.
     You need some SFE framework (try TASTY and/or Fairplay).
     SFE comes with some performance impact, so think about
     additional optimizations.
     Also, some SFE schemes are by default only secure against
     honest-but-curious attackers. Need to add zero-knowledge or
     other tricks to improve that.
     For additional details, please check out our article in Phrack
     #68.


                                               Secure Function Evaluation vs. Deniability
Introduction
                                     OTR
                                Deniability
               Secure Function Evaluation
                   Putting It All Together
                                  The End


OTR Related Details


     OTR mandates kM = Hash(kE ), so A is not allowed to know
     kE . Can be solved by also sharing kE with O and cooperating
     for encryption and decryption.
     A needs to convince O that she doesn’t do re-keyings that O
     doesn’t know about (can be done by using zero-knowledge
     proofs).
     OTR mandates you should publish your MAC keys when you
     won’t use them anymore. The current implementation doesn’t
     check that but if it would, we’d also need to do that
     cooperatively.


                                              Secure Function Evaluation vs. Deniability
Introduction
                                      OTR
                                 Deniability
                Secure Function Evaluation
                    Putting It All Together
                                   The End


Optimizing DH

     Computing modular exponentiation is expensive. Even more
     so in a circuit. Fortunately, DH can be tweaked, so that we
     only need to do a multiplication in SFE.
     A picks some random value j and does the following:
      O                      A               B
                                                      gb
                                               ←− −−
                                                −−−
                   g ab+j
           ←−−−−−−
            −−−−−−
                    go
            −− − − − −
            − − − − −→
     O computes (g ab+j )o = g abo+jo
     A computes g −jo (trivial to invert g j )
     Using SFE, A and O compute g abo = g abo+jo · g −jo
                                               Secure Function Evaluation vs. Deniability
Introduction
                                  OTR
                             Deniability
            Secure Function Evaluation
                Putting It All Together
                               The End




                         Questions?


                     Get in touch:
Mail: ping@gregorkopf.de,         twitter: teh gerg
Mail: bbrehm@math.fu-berlin.de, twitter: bruhn5




                                           Secure Function Evaluation vs. Deniability

Más contenido relacionado

Destacado

Prenez votre pied avec les bots et cognitive services.
Prenez votre pied avec les bots et cognitive services.Prenez votre pied avec les bots et cognitive services.
Prenez votre pied avec les bots et cognitive services.Microsoft
 
Otr Wheel Engineering - Wheel inspection program 2012
Otr Wheel Engineering - Wheel inspection program 2012Otr Wheel Engineering - Wheel inspection program 2012
Otr Wheel Engineering - Wheel inspection program 2012OTR Wheel Engineering, Inc
 
WhatsApp Encryption Overview, Whitepaper
WhatsApp Encryption Overview, WhitepaperWhatsApp Encryption Overview, Whitepaper
WhatsApp Encryption Overview, WhitepaperMarco Antúnez Piña
 
12 symmetric key cryptography
12   symmetric key cryptography12   symmetric key cryptography
12 symmetric key cryptographydrewz lin
 
Different types of Symmetric key Cryptography
Different types of Symmetric key CryptographyDifferent types of Symmetric key Cryptography
Different types of Symmetric key Cryptographysubhradeep mitra
 
畅聊XMPP/Jabber
畅聊XMPP/Jabber畅聊XMPP/Jabber
畅聊XMPP/JabberBSEC
 
WhatsApp Telemedicine For the Developing World: What Can We Learn From India ...
WhatsApp Telemedicine For the Developing World: What Can We Learn From India ...WhatsApp Telemedicine For the Developing World: What Can We Learn From India ...
WhatsApp Telemedicine For the Developing World: What Can We Learn From India ...Apollo Hospitals Group and ATNF
 
Whats app aplication peer review
Whats app aplication  peer reviewWhats app aplication  peer review
Whats app aplication peer reviewu2910635
 
What Facebook acquisition of WhatsApp means for Simplify360
What Facebook acquisition of WhatsApp means for Simplify360What Facebook acquisition of WhatsApp means for Simplify360
What Facebook acquisition of WhatsApp means for Simplify360Simplify360
 
3 public key cryptography
3 public key cryptography3 public key cryptography
3 public key cryptographyRutvik Mehta
 
Android– forensics and security testing
Android– forensics and security testingAndroid– forensics and security testing
Android– forensics and security testingSanthosh Kumar
 

Destacado (16)

Off-The-Record (OTR)
Off-The-Record (OTR)Off-The-Record (OTR)
Off-The-Record (OTR)
 
2
22
2
 
Whisper System Presentation
Whisper System PresentationWhisper System Presentation
Whisper System Presentation
 
Prenez votre pied avec les bots et cognitive services.
Prenez votre pied avec les bots et cognitive services.Prenez votre pied avec les bots et cognitive services.
Prenez votre pied avec les bots et cognitive services.
 
OTR and XMPP
OTR and XMPPOTR and XMPP
OTR and XMPP
 
Otr Wheel Engineering - Wheel inspection program 2012
Otr Wheel Engineering - Wheel inspection program 2012Otr Wheel Engineering - Wheel inspection program 2012
Otr Wheel Engineering - Wheel inspection program 2012
 
WhatsApp Encryption Overview, Whitepaper
WhatsApp Encryption Overview, WhitepaperWhatsApp Encryption Overview, Whitepaper
WhatsApp Encryption Overview, Whitepaper
 
12 symmetric key cryptography
12   symmetric key cryptography12   symmetric key cryptography
12 symmetric key cryptography
 
Different types of Symmetric key Cryptography
Different types of Symmetric key CryptographyDifferent types of Symmetric key Cryptography
Different types of Symmetric key Cryptography
 
畅聊XMPP/Jabber
畅聊XMPP/Jabber畅聊XMPP/Jabber
畅聊XMPP/Jabber
 
WhatsApp Forensic
WhatsApp ForensicWhatsApp Forensic
WhatsApp Forensic
 
WhatsApp Telemedicine For the Developing World: What Can We Learn From India ...
WhatsApp Telemedicine For the Developing World: What Can We Learn From India ...WhatsApp Telemedicine For the Developing World: What Can We Learn From India ...
WhatsApp Telemedicine For the Developing World: What Can We Learn From India ...
 
Whats app aplication peer review
Whats app aplication  peer reviewWhats app aplication  peer review
Whats app aplication peer review
 
What Facebook acquisition of WhatsApp means for Simplify360
What Facebook acquisition of WhatsApp means for Simplify360What Facebook acquisition of WhatsApp means for Simplify360
What Facebook acquisition of WhatsApp means for Simplify360
 
3 public key cryptography
3 public key cryptography3 public key cryptography
3 public key cryptography
 
Android– forensics and security testing
Android– forensics and security testingAndroid– forensics and security testing
Android– forensics and security testing
 

Más de Yury Chemerkin

Security Vulnerability Notice SE-2012-01-PUBLIC [Security vulnerabilities in ...
Security Vulnerability Notice SE-2012-01-PUBLIC [Security vulnerabilities in ...Security Vulnerability Notice SE-2012-01-PUBLIC [Security vulnerabilities in ...
Security Vulnerability Notice SE-2012-01-PUBLIC [Security vulnerabilities in ...Yury Chemerkin
 
Red october. detailed malware description
Red october. detailed malware descriptionRed october. detailed malware description
Red october. detailed malware descriptionYury Chemerkin
 
Comment crew indicators of compromise
Comment crew indicators of compromiseComment crew indicators of compromise
Comment crew indicators of compromiseYury Chemerkin
 
Appendix g iocs readme
Appendix g iocs readmeAppendix g iocs readme
Appendix g iocs readmeYury Chemerkin
 
Appendix f (digital) ssl certificates
Appendix f (digital)   ssl certificatesAppendix f (digital)   ssl certificates
Appendix f (digital) ssl certificatesYury Chemerkin
 
Appendix e (digital) md5s
Appendix e (digital)   md5sAppendix e (digital)   md5s
Appendix e (digital) md5sYury Chemerkin
 
Appendix d (digital) fqd ns
Appendix d (digital)   fqd nsAppendix d (digital)   fqd ns
Appendix d (digital) fqd nsYury Chemerkin
 
6071f3f4 40e6-4c7b-8868-3b0b21a9f601
6071f3f4 40e6-4c7b-8868-3b0b21a9f6016071f3f4 40e6-4c7b-8868-3b0b21a9f601
6071f3f4 40e6-4c7b-8868-3b0b21a9f601Yury Chemerkin
 
Zane lackey. security at scale. web application security in a continuous depl...
Zane lackey. security at scale. web application security in a continuous depl...Zane lackey. security at scale. web application security in a continuous depl...
Zane lackey. security at scale. web application security in a continuous depl...Yury Chemerkin
 
Windows 8. important considerations for computer forensics and electronic dis...
Windows 8. important considerations for computer forensics and electronic dis...Windows 8. important considerations for computer forensics and electronic dis...
Windows 8. important considerations for computer forensics and electronic dis...Yury Chemerkin
 
The stuxnet computer worm. harbinger of an emerging warfare capability
The stuxnet computer worm. harbinger of an emerging warfare capabilityThe stuxnet computer worm. harbinger of an emerging warfare capability
The stuxnet computer worm. harbinger of an emerging warfare capabilityYury Chemerkin
 
Stuxnet. analysis, myths, realities
Stuxnet. analysis, myths, realitiesStuxnet. analysis, myths, realities
Stuxnet. analysis, myths, realitiesYury Chemerkin
 
Stuxnet redux. malware attribution & lessons learned
Stuxnet redux. malware attribution & lessons learnedStuxnet redux. malware attribution & lessons learned
Stuxnet redux. malware attribution & lessons learnedYury Chemerkin
 
Sophos ransom ware fake antivirus
Sophos ransom ware fake antivirusSophos ransom ware fake antivirus
Sophos ransom ware fake antivirusYury Chemerkin
 
Six months later – a report card on google’s demotion of pirate sites
Six months later – a report card on google’s demotion of pirate sitesSix months later – a report card on google’s demotion of pirate sites
Six months later – a report card on google’s demotion of pirate sitesYury Chemerkin
 
Security in the cloud planning guide
Security in the cloud planning guideSecurity in the cloud planning guide
Security in the cloud planning guideYury Chemerkin
 
Security configuration recommendations for apple i os 5 devices
Security configuration recommendations for apple i os 5 devicesSecurity configuration recommendations for apple i os 5 devices
Security configuration recommendations for apple i os 5 devicesYury Chemerkin
 
Render man. hacker + airplanes = no good can come of this
Render man. hacker + airplanes = no good can come of thisRender man. hacker + airplanes = no good can come of this
Render man. hacker + airplanes = no good can come of thisYury Chemerkin
 

Más de Yury Chemerkin (20)

Security Vulnerability Notice SE-2012-01-PUBLIC [Security vulnerabilities in ...
Security Vulnerability Notice SE-2012-01-PUBLIC [Security vulnerabilities in ...Security Vulnerability Notice SE-2012-01-PUBLIC [Security vulnerabilities in ...
Security Vulnerability Notice SE-2012-01-PUBLIC [Security vulnerabilities in ...
 
Red october. detailed malware description
Red october. detailed malware descriptionRed october. detailed malware description
Red october. detailed malware description
 
Comment crew indicators of compromise
Comment crew indicators of compromiseComment crew indicators of compromise
Comment crew indicators of compromise
 
Appendix g iocs readme
Appendix g iocs readmeAppendix g iocs readme
Appendix g iocs readme
 
Appendix f (digital) ssl certificates
Appendix f (digital)   ssl certificatesAppendix f (digital)   ssl certificates
Appendix f (digital) ssl certificates
 
Appendix e (digital) md5s
Appendix e (digital)   md5sAppendix e (digital)   md5s
Appendix e (digital) md5s
 
Appendix d (digital) fqd ns
Appendix d (digital)   fqd nsAppendix d (digital)   fqd ns
Appendix d (digital) fqd ns
 
6071f3f4 40e6-4c7b-8868-3b0b21a9f601
6071f3f4 40e6-4c7b-8868-3b0b21a9f6016071f3f4 40e6-4c7b-8868-3b0b21a9f601
6071f3f4 40e6-4c7b-8868-3b0b21a9f601
 
Jp3 13
Jp3 13Jp3 13
Jp3 13
 
Zane lackey. security at scale. web application security in a continuous depl...
Zane lackey. security at scale. web application security in a continuous depl...Zane lackey. security at scale. web application security in a continuous depl...
Zane lackey. security at scale. web application security in a continuous depl...
 
Windows 8. important considerations for computer forensics and electronic dis...
Windows 8. important considerations for computer forensics and electronic dis...Windows 8. important considerations for computer forensics and electronic dis...
Windows 8. important considerations for computer forensics and electronic dis...
 
The stuxnet computer worm. harbinger of an emerging warfare capability
The stuxnet computer worm. harbinger of an emerging warfare capabilityThe stuxnet computer worm. harbinger of an emerging warfare capability
The stuxnet computer worm. harbinger of an emerging warfare capability
 
Stuxnet. analysis, myths, realities
Stuxnet. analysis, myths, realitiesStuxnet. analysis, myths, realities
Stuxnet. analysis, myths, realities
 
Stuxnet redux. malware attribution & lessons learned
Stuxnet redux. malware attribution & lessons learnedStuxnet redux. malware attribution & lessons learned
Stuxnet redux. malware attribution & lessons learned
 
Sophos ransom ware fake antivirus
Sophos ransom ware fake antivirusSophos ransom ware fake antivirus
Sophos ransom ware fake antivirus
 
Six months later – a report card on google’s demotion of pirate sites
Six months later – a report card on google’s demotion of pirate sitesSix months later – a report card on google’s demotion of pirate sites
Six months later – a report card on google’s demotion of pirate sites
 
Security in the cloud planning guide
Security in the cloud planning guideSecurity in the cloud planning guide
Security in the cloud planning guide
 
Security configuration recommendations for apple i os 5 devices
Security configuration recommendations for apple i os 5 devicesSecurity configuration recommendations for apple i os 5 devices
Security configuration recommendations for apple i os 5 devices
 
Render man. hacker + airplanes = no good can come of this
Render man. hacker + airplanes = no good can come of thisRender man. hacker + airplanes = no good can come of this
Render man. hacker + airplanes = no good can come of this
 
Msft oracle brief
Msft oracle briefMsft oracle brief
Msft oracle brief
 

Último

Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsJoaquim Jorge
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUK Journal
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationSafe Software
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024SynarionITSolutions
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesBoston Institute of Analytics
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfsudhanshuwaghmare1
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationRadu Cotescu
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024The Digital Insurer
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024The Digital Insurer
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityPrincipled Technologies
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businesspanagenda
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoffsammart93
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 

Último (20)

Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Artificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and MythsArtificial Intelligence: Facts and Myths
Artificial Intelligence: Facts and Myths
 
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdfUnderstanding Discord NSFW Servers A Guide for Responsible Users.pdf
Understanding Discord NSFW Servers A Guide for Responsible Users.pdf
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time AutomationFrom Event to Action: Accelerate Your Decision Making with Real-Time Automation
From Event to Action: Accelerate Your Decision Making with Real-Time Automation
 
Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024Top 10 Most Downloaded Games on Play Store in 2024
Top 10 Most Downloaded Games on Play Store in 2024
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
HTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation StrategiesHTML Injection Attacks: Impact and Mitigation Strategies
HTML Injection Attacks: Impact and Mitigation Strategies
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Boost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdfBoost Fertility New Invention Ups Success Rates.pdf
Boost Fertility New Invention Ups Success Rates.pdf
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Scaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organizationScaling API-first – The story of a global engineering organization
Scaling API-first – The story of a global engineering organization
 
Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024Manulife - Insurer Innovation Award 2024
Manulife - Insurer Innovation Award 2024
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
Boost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivityBoost PC performance: How more available memory can improve productivity
Boost PC performance: How more available memory can improve productivity
 
Why Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire businessWhy Teams call analytics are critical to your entire business
Why Teams call analytics are critical to your entire business
 
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot TakeoffStrategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
Strategize a Smooth Tenant-to-tenant Migration and Copilot Takeoff
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 

Gregor kopf , bernhard brehm. deniability in messaging protocols

  • 1. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Secure Function Evaluation vs. Deniability In OTR and Similar Protocols bruhns, greg CONFidence 2012 Secure Function Evaluation vs. Deniability
  • 2. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End What and why? OTR is a popular cryptographic protocol. It features a number of properties, such as confidentiality, integrity and also deniability. We’re going to focus on the deniability aspect of the protocol. Secure Function Evaluation vs. Deniability
  • 3. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End TOC 1 Introduction 2 OTR 3 Deniability 4 Secure Function Evaluation 5 Putting It All Together 6 The End Secure Function Evaluation vs. Deniability
  • 4. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End OTR Secure Function Evaluation vs. Deniability
  • 5. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End OTR Off-the-Record Messaging Cryptographic protocol for instant messaging Interesting properties Confidentiality Integrity Forward Secrecy Mutual authentication using SMP Deniability Secure Function Evaluation vs. Deniability
  • 6. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Security Properties General setting: Alice ↔ Eve ↔ Bob Confidentiality & Integrity Eve cannot decipher any of Bob’s or Alice’s messages. Neither can she modify any of those messages (without Alice or Bob noticing that). Forward Secrecy Suppose Alice looses her private key. Eve should not be able to decipher any messages that has already been sent in a prior conversation between Alice and Bob. Mutual authentication Alice and Bob can authenticate each other. Secure Function Evaluation vs. Deniability
  • 7. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Security Properties General setting: Alice ↔ Eve ↔ Bob Confidentiality & Integrity Eve cannot decipher any of Bob’s or Alice’s messages. Neither can she modify any of those messages (without Alice or Bob noticing that). Forward Secrecy Suppose Alice looses her private key. Eve should not be able to decipher any messages that has already been sent in a prior conversation between Alice and Bob. Mutual authentication Alice and Bob can authenticate each other. Secure Function Evaluation vs. Deniability
  • 8. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Security Properties General setting: Alice ↔ Eve ↔ Bob Confidentiality & Integrity Eve cannot decipher any of Bob’s or Alice’s messages. Neither can she modify any of those messages (without Alice or Bob noticing that). Forward Secrecy Suppose Alice looses her private key. Eve should not be able to decipher any messages that has already been sent in a prior conversation between Alice and Bob. Mutual authentication Alice and Bob can authenticate each other. Secure Function Evaluation vs. Deniability
  • 9. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Security Properties General setting: Alice ↔ Eve ↔ Bob Confidentiality & Integrity Eve cannot decipher any of Bob’s or Alice’s messages. Neither can she modify any of those messages (without Alice or Bob noticing that). Forward Secrecy Suppose Alice looses her private key. Eve should not be able to decipher any messages that has already been sent in a prior conversation between Alice and Bob. Mutual authentication Alice and Bob can authenticate each other. Secure Function Evaluation vs. Deniability
  • 10. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Security Properties General setting: Alice ↔ Eve ↔ Bob Deniability Both, Alice and Bob are hackers and talk about serious stuff (TM) using OTR. Now Alice turns evil and wants to backstab on Bob. Debiability means that Alice can not prove that Bob was really the author of any message he sent (yet, during the conversation Alice is still sure that she talks to Bob). Secure Function Evaluation vs. Deniability
  • 11. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Key Exchange & Message Crypto Simplified version of the protocol: Each party has an asymmetric key pair, which we’ll call master key Use Diffie-Hellman to establish a common set of encryption and authentication keys. Alice and Bob sign their Diffie-Hellman messages with their master keys. → Authentication and Forward Secrecy → Deniability (weak) Messages are encrypted (AES-CTR) and MACed (HMAC) using the symmtric keys that have been generated. → Confidentiality and integrity Secure Function Evaluation vs. Deniability
  • 12. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Key Exchange & Message Crypto Each message contains a new DH key exchange proposal (also MACed of course). As soon as new keys have been established, the old MAC keys are made public. → Deniability (strong) Secure Function Evaluation vs. Deniability
  • 13. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Re-Keying Both parties frequently re-key the symmetric primitives. The re-keying procedure is significantly simpler than the initial key-exchange - we already have key material exchanged. General approach: Perform a DH key-exchange and use already established MAC keys to authenticate the communication. Advantage: We can publish the “old” MAC keys, as they are not longer used. We will not disclose our encryption keys, though! Secure Function Evaluation vs. Deniability
  • 14. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Deniability Secure Function Evaluation vs. Deniability
  • 15. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Deniability How could Alice attack Bob’s deniability? +-------+ "I pwn3d XYZ", sig(..) +-------+ | Alice | <-----------------------> | Bob | +-------+ +-------+ ^ | "Bob pwn3d XYZ, here’s a proof" +-------+ +---------------------------------> | Judge | +-------+ Simple offline attack Bob will argue that Alice just made up the signature. She can do that, because OTR is deniable (more on that later). But Alice might try something else. . . Secure Function Evaluation vs. Deniability
  • 16. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Deniability How could Alice attack Bob’s deniability? +-------+ "I pwn3d XYZ", sig(..) +-------+ | Alice | <-----------------------> | Bob | +-------+ ^ +-------+ ^ | | +---- Sniff ------------+ | | | "See? Bob really said he pwn3d XYZ." +-------+ +------------------------------------> | Judge | +-------+ If the judge sniffs all traffic, he knows that Bob said. Alice can give him the encryption/MAC key and he can verify that. Hard to implement (especially if Alice/Bob use an anonymizer). Secure Function Evaluation vs. Deniability
  • 17. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Deniability How could Alice attack Bob’s deniability? +-------+ +-------+ | Alice |<-+ +->| Bob | +-------+ | | +-------+ | | v v +-------+ | Judge | +-------+ Online attack: Alice forwards all traffic to the judge. Also won’t work: Bob will again argue that Alice faked the messages. Alice gives her master key to the judge, who will act as a proxy for Alice. He will read all messages, check integrity and authentication. Secure Function Evaluation vs. Deniability
  • 18. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Deniability How could Alice attack Bob’s deniability? +-------+ +-------+ | Alice |<-+ +->| Bob | +-------+ | | +-------+ | | v v +-------+ | Judge | +-------+ But now the judge can impersonate Alice and Alice doesn’t really trust the judge. What if there was a party that both, Alice and the judge, trust? Secure Function Evaluation vs. Deniability
  • 19. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Deniability How could Alice attack Bob’s deniability? +-------+ +-------+ | Alice |<-+ +->| Bob | +-------+ | | +-------+ | | v v +----------------+ +-------+ | Alice’s Lawyer | <---> | Judge | +----------------+ +-------+ Alice just gives her master keys to her lawyer. That looks pretty good. But Alice has some doubts. . . Does the judge really trust her lawyer? Worse: does she really trust her lawyer? Secure Function Evaluation vs. Deniability
  • 20. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Deniability How could Alice attack Bob’s deniability? +-------+ +-------+ | Alice |<-+ +->| Bob | +-------+ | | +-------+ | | v v +----------------+ +-------+ | Alice’s Lawyer | <---> | Judge | +----------------+ +-------+ Lucky us: We’re all paranoid and there is no trusted third party. Alice’s goal: get rid of the lawyer! Secure Function Evaluation vs. Deniability
  • 21. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Deniability There are actually two concepts of deniability: weak and strong deniability. Weak deniability: If one party discloses a message sent by the other party, the other party can claim that the message was actually faked by the disclosing party. Strong deniability: If a message gets disclosed, each party can claim that anybody could have faked that message. Weak deniability is pretty obvious: both parties are in possession of encryption and MAC keys, so there is no way to distinguish who actually sent a message. Attacks can be offline (observer not involved in the conversation) and online (observer is involved in the conversation). Secure Function Evaluation vs. Deniability
  • 22. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Strong Deniability That’s a bit harder. The main idea here is that after each re-keying, the old MAC keys are disclosed. In order to fake a message, we need to know two things: MAC key (is public) and encryption key. The encryption key is never disclosed to the public, because that would violate the confidentiality. But using the MAC key, we can create a fake re-keying event, so that encryption and MAC keys are generated, which we know. Now we can forge any message transcript. Secure Function Evaluation vs. Deniability
  • 23. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End What Does OTR Offer? OTR claims strong deniability. Deniability does not protect against someone who was evil right from the beginning! Such individuals could just share their master keys with any agency. If they are able to sniff your traffic, you’re screwed, too: they know, which messages you sent. But sniffing each and every network communication doesn’t scale well. Also, if your peer wasn’t evil right from the beginning, we cannot assume a trust relation between him and the attacker(s). Secure Function Evaluation vs. Deniability
  • 24. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Secure Function Evaluation Secure Function Evaluation vs. Deniability
  • 25. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Secure Function Evaluation Remember: Alice wanted to get rid of the lawyer. Doesn’t look like an easy task. But isn’t there any way to “emulate” that trusted third party? Crypto teaches us the surprising result: there actually is! It’s called Secure Function Evaluation (SFE). Secure Function Evaluation vs. Deniability
  • 26. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End SFE A method for securely computing f (x, y ), where you know x, your peer knows y and neither you nor your peer want the other to learn x or y . Different approaches for implementing SFE (Partially) homomorphic cryptosystems Yao’s Garbled Circuits Secure Function Evaluation vs. Deniability
  • 27. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Oblivious Transfer Bob knows two values, x0 and x1 . He is willing to share exactly one with Alice. Alice wants one of those values, but doesn’t want to tell Bob, which one she wants. This problem is solved by oblivious transfer. There are many OT schemes out there, often based on trapdoor one-way functions. You can imagine those as instances of RSA, where f is the encryption function and f −1 the decryption function (keys are fixed). Secure Function Evaluation vs. Deniability
  • 28. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End OT: Compact Version Bob knows x0 and x1 , Alice wants to receive one of them (xb with b ∈ {0, 1}) A B Pick f , f −1 , r0 , r1 f ,r0 ,r1 ←− − − − − − − − − − − − − − − −− Pick k compute z = f (k) z=f (k)⊕rb −− − − − − − − − − − − − − − − −→ Compute candidates k0 = f −1 (z ⊕ r0 ) and k1 x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 ) ←−−−−−−−− −−−−−−−−− Secure Function Evaluation vs. Deniability
  • 29. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End OT: Compact Version Bob knows x0 and x1 , Alice wants to receive one of them (xb with b ∈ {0, 1}) A B Pick f , f −1 , r0 , r1 f ,r0 ,r1 ←− − − − − − − − − − − − − − − −− Pick k compute z = f (k) z=f (k)⊕rb −− − − − − − − − − − − − − − − −→ Compute candidates k0 = f −1 (z ⊕ r0 ) and k1 x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 ) ←−−−−−−−− −−−−−−−−− Secure Function Evaluation vs. Deniability
  • 30. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End OT: Compact Version Bob knows x0 and x1 , Alice wants to receive one of them (xb with b ∈ {0, 1}) A B Pick f , f −1 , r0 , r1 f ,r0 ,r1 ←− − − − − − − − − − − − − − − −− Pick k compute z = f (k) z=f (k)⊕rb −− − − − − − − − − − − − − − − −→ Compute candidates k0 = f −1 (z ⊕ r0 ) and k1 x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 ) ←−−−−−−−− −−−−−−−−− Secure Function Evaluation vs. Deniability
  • 31. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End OT: Compact Version Bob knows x0 and x1 , Alice wants to receive one of them (xb with b ∈ {0, 1}) A B Pick f , f −1 , r0 , r1 f ,r0 ,r1 ←− − − − − − − − − − − − − − − −− Pick k compute z = f (k) z=f (k)⊕rb −− − − − − − − − − − − − − − − −→ Compute candidates k0 = f −1 (z ⊕ r0 ) and k1 x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 ) ←−−−−−−−− −−−−−−−−− Secure Function Evaluation vs. Deniability
  • 32. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End OT: Compact Version Bob knows x0 and x1 , Alice wants to receive one of them (xb with b ∈ {0, 1}) A B Pick f , f −1 , r0 , r1 f ,r0 ,r1 ←− − − − − − − − − − − − − − − −− Pick k compute z = f (k) z=f (k)⊕rb −− − − − − − − − − − − − − − − −→ Compute candidates k0 = f −1 (z ⊕ r0 ) and k1 x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 ) ←−−−−−−−− −−−−−−−−− Secure Function Evaluation vs. Deniability
  • 33. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End OT: Compact Version Bob knows x0 and x1 , Alice wants to receive one of them (xb with b ∈ {0, 1}) A B Pick f , f −1 , r0 , r1 f ,r0 ,r1 ←− − − − − − − − − − − − − − − −− Pick k compute z = f (k) z=f (k)⊕rb −− − − − − − − − − − − − − − − −→ Compute candidates k0 = f −1 (z ⊕ r0 ) and k1 x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 ) ←−−−−−−−− −−−−−−−−− Secure Function Evaluation vs. Deniability
  • 34. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End OT: Compact Version Bob knows x0 and x1 , Alice wants to receive one of them (xb with b ∈ {0, 1}) A B Pick f , f −1 , r0 , r1 f ,r0 ,r1 ←− − − − − − − − − − − − − − − −− Pick k compute z = f (k) z=f (k)⊕rb −− − − − − − − − − − − − − − − −→ Compute candidates k0 = f −1 (z ⊕ r0 ) and k1 x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 ) ←−−−−−−−− −−−−−−−−− Secure Function Evaluation vs. Deniability
  • 35. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End General OT Approach Bob choses f , f −1 (trapdoor one-way!) and sends f to Alice. Also, Bob picks two random values r0 and r1 , which he also sends to Alice. Alice wants to retrieve value xb from Bob. She first generates a random value k and computes z = f (k) ⊕ rb , which she sends to Bob. Bob computes k0 = f −1 (z ⊕ r0 ) and k1 = f −1 (z ⊕ r1 ). He can be sure that one of those k values is correct and the other one is junk. He computes x0 = x0 ⊕ k0 and x1 = x1 ⊕ k1 , which he sends to Alice. Alice receives x0 and x1 , but she can only decrypt one of them, because she only knows one k value. Secure Function Evaluation vs. Deniability
  • 36. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End GC SFE Evalution of boolean circuits (non-uniform computation) Functions can be modeled as circuits. That’s what happens when you program an FPGA. A circuit consists of gates and wires connecting those gates. Alice and Bob agree on a circuit. Alice “garbles” it and Bob evaluates the garbled circuit. Gates can be represented by their truth tables. For example: 0 1 0 0 0 1 0 1 Secure Function Evaluation vs. Deniability
  • 37. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Garbling a Gate Main idea: replace the binary inputs by (long) random strings. Instead of 1 or 0, we use keys like 350d5ea01e8a1f407cf or 763581eb6cea7ec4b9a6e. Pick such random keys for each value of each wire (if we have inputs a and b, we’ll call the keys ka0 , ka1 , kb0 and kb1 ). Encrypt the truth table of the gate using the generated keys. Pick an encryption function E , decryption function D. Let D be built in such a way that it will complain if wrong keys are used (instead of just decrypting junk). 0 1 0 1 0 0 0 → 0 Eka0 (Ekb0 (0)) Eka1 (Ekb0 (0)) 1 0 1 1 Eka0 (Ekb1 (0)) Eka1 (Ekb1 (1)) Secure Function Evaluation vs. Deniability
  • 38. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Garbling a Circuit Out When you have the input keys, just try to | decrypt all entries in a garbled gate until +------+ one operation succeeds. | G1 | In1 , In2 and In4 are known (will cover that +------+ later) | | But where to get In3 from? Simple trick: In_3 | | We put the key In3 into the garbled table | | of G 2. +---+ In_4 0 1 |G2 | 0 Eka0 (Ekb0 (In30 )) Eka1 (Ekb0 (In30 )) +---+ 1 Eka0 (Ekb1 (In30 )) Eka1 (Ekb1 (In31 )) | In_1 In_2 Secure Function Evaluation vs. Deniability
  • 39. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Evaluating a GC Where to get the input keys from? Alice can hard-code her inputs into the circuit when garbling it. Bob however doesn’t know the keys for his inputs. Bob could just ask Alice to give him the keys for his input values. But either he tells Alice what his input values are or Alice gives him the keys for all input values. Neither is acceptable. Solution: Oblivious transfer After Bob obliviously received his garbled input values, he evaluates the circuit, sends the result over to Alice and Alice de-garbles it. Secure Function Evaluation vs. Deniability
  • 40. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Putting It All Together Secure Function Evaluation vs. Deniability
  • 41. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End The Attack Idea SFE can be used to emulate a trusted third party. That is: Instead of letting a trusted third party compute some function for us, we can just do that ourselves and still have the same security properties. Use SFE to emulate a trusted third party: Somehow (TM) share our keys with that “third party”. Secure Function Evaluation vs. Deniability
  • 42. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Sharing is Caring We want to backstab our peer, therefore we collaborate with an observing party O (a.k.a. the judge or simply them). We keep our asymmetric master keys for ourselves. But every DH key exchange, we compute together with O. The resulting MAC keys are shared between O and us (i.e. neither O nor we know the keys, details later). The encryption keys are only known to us (otherwise, O could learn the plain text). To verify a message’s integrity, we collaborate with O. For signing a message, we also collaborate with O. Secure Function Evaluation vs. Deniability
  • 43. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Recap: Diffie-Hellman A and B publicly agree on a prime p and a generator g of a large cyclic subgroup of Zp . A picks a random a, computes g a . Same for B. A and B exchange g a and g b , but keep a and b secret. A computes k = (g b )a , B computes k = (g a )b . Both keys are the same k = g ab = g ba . An attacker cannot compute g ab from g a and g b alone (Diffie-Hellman problem). Secure Function Evaluation vs. Deniability
  • 44. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End The Attack Implementation Cooperative key-exchange: consider three parties A, B and O (Alice, Bob and the observing party). A and O cooperate. O A B ga ←− − − − − − − − − −− go −− − − − − − − − − −→ g ao −− − − − − − − − − −→ gb ←− − − − − − − − − −− B now knows g abo , but neither A not O can compute that value. Proof idea: A knows g b , g o and a. Computing g oab ↔ computing g bo , equivalent to the Diffie-Hellman problem. Secure Function Evaluation vs. Deniability
  • 45. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End The Attack Implementation No SFE up to here! A and O both know g b . With their private exponents, A and O can compute g abo . But A and O don’t want to share a and o. From g abo , A and B can compute the encryption and MAC keys (those are generated by hasing g abo in various ways). The function that A and O want to compute is f (a, b) = (kE , kM ) = (HASHE (((g b )a )o ), HASHM (((g b )a )o )). Inputs of the function are the private exponents a and o. The circuit for that is rather big. . . Secure Function Evaluation vs. Deniability
  • 46. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Cleanup But now O knows the MAC key and could impersonate A and B. . . Fix: A has to get kE and A, O have to share kM ! Easily possible by using a circuit that blinds some of its outputs with a key only known to one party: The circuit takes an additional input x and instead of kM it really computes kM ⊕ x. A will know kx := kM ⊕ x and O will know x. For every MAC computation, A and O will jointly compute f (kx , x, m) = HMAC (m, kx ⊕ x). Secure Function Evaluation vs. Deniability
  • 47. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End The Big Picture: Key Exchange O A B go −− − − − − − − − − − − − − − − −→ ga ←− − − − − − − − − − − − − − − −− g ao −−−−−−−−− −−−−−−−−→ gb ←− − − − − − − − − − − − − − − −− f ,r0 ,r1 ←− − − − − − − − − − − − − − − −− z=f (k)⊕rb −− − − − − − − − − − − − − − − −→ x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 ) ←−−−−−−−− −−−−−−−−− . . . C ←−−−−−−−− −−−−−−−− eval(C )=kE ,kM ⊕x −− − − − − − − − − − − − − − − −→ Secure Function Evaluation vs. Deniability
  • 48. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End The Big Picture: Message Exchange O A B E (m),HMAC (E (m)) ←− − − − − − − − − − − − − − − −− C ,f ,r0 ,r1 ←−−−−−−− −−−−−−− z=f (k)⊕rb −− − − − − − −→ −−−−−−−− x0 ⊕f −1 (z⊕r0 ),x1 ⊕f −1 (z⊕r1 ) ←−−−−−−−− −−−−−−−−− . . . eval(C )=HMAC (E (m)) −− − − − − − − − − − − − − − − − − −→ Secure Function Evaluation vs. Deniability
  • 49. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Security Properties of Our Scheme O will never see any plain text, so confidentiality stays. Without our help, O cannot sign or verify any message, so integrity also stays intact. Forward secrecy also remains OK, because O won’t learn any decryption keys anyway. Secure Function Evaluation vs. Deniability
  • 50. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Security Properties of Our Scheme But deniability is gone: As we need the help of O to verify the messages of our peer, O learns about the integrity of the messages at the same time as we do. Messages that are created afterwards will be rejected by O, just because O has not seen those during the conversation. Even worse: We can selectively disclose any message content to O, just by telling O the decryption key for that particular message! This scheme can be extended to other protocols as well! Secure Function Evaluation vs. Deniability
  • 51. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End What’s the Benefit of Our Scenario? No trust relationship with O is required (on no side). O doesn’t have to sniff anything. You don’t have to disclose everything you or your peer said. No “evil” intentions required. People might use it as a defense: “just to be sure.. if my peer turns evil at some point in time then I’ll disclose everything he said!” Secure Function Evaluation vs. Deniability
  • 52. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Closing remarks “So who is that obverving party?” They might be the NSA or anybody else. Probably the adversary you’re most afraid of. “Yeah, but you know what: they still cannot prove anything to (yet) another party. And in my country, you actually need to prove stuff in court!!1” Might be (are you sure?) But what if they are the judges / the jury? Cooperating “just to be safe” → prisoners dilemma Secure Function Evaluation vs. Deniability
  • 53. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Implementation Considerations A real-world implementation would be more complicated (OTR has some restrictions that we left out) but can be done. You need some SFE framework (try TASTY and/or Fairplay). SFE comes with some performance impact, so think about additional optimizations. Also, some SFE schemes are by default only secure against honest-but-curious attackers. Need to add zero-knowledge or other tricks to improve that. For additional details, please check out our article in Phrack #68. Secure Function Evaluation vs. Deniability
  • 54. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End OTR Related Details OTR mandates kM = Hash(kE ), so A is not allowed to know kE . Can be solved by also sharing kE with O and cooperating for encryption and decryption. A needs to convince O that she doesn’t do re-keyings that O doesn’t know about (can be done by using zero-knowledge proofs). OTR mandates you should publish your MAC keys when you won’t use them anymore. The current implementation doesn’t check that but if it would, we’d also need to do that cooperatively. Secure Function Evaluation vs. Deniability
  • 55. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Optimizing DH Computing modular exponentiation is expensive. Even more so in a circuit. Fortunately, DH can be tweaked, so that we only need to do a multiplication in SFE. A picks some random value j and does the following: O A B gb ←− −− −−− g ab+j ←−−−−−− −−−−−− go −− − − − − − − − − −→ O computes (g ab+j )o = g abo+jo A computes g −jo (trivial to invert g j ) Using SFE, A and O compute g abo = g abo+jo · g −jo Secure Function Evaluation vs. Deniability
  • 56. Introduction OTR Deniability Secure Function Evaluation Putting It All Together The End Questions? Get in touch: Mail: ping@gregorkopf.de, twitter: teh gerg Mail: bbrehm@math.fu-berlin.de, twitter: bruhn5 Secure Function Evaluation vs. Deniability