Uploaded image for project: 'Erlang/OTP'
  1. Erlang/OTP
  2. ERL-1073

cb_info callback for "open" when using dtls doesn't have expected options

    XMLWordPrintable

    Details

    • Type: New Feature
    • Status: In Progress
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: 19.1.1
    • Fix Version/s: None
    • Component/s: ssl
    • Labels:

      Description

      I'm trying to use the dtls protocol, with my own callback because I need to run it over a udp "socket" I've already established. (This is because I need to switch between processing "ICE/Stun, then DTLS, then SRTP over the same UDP port)

         Opts = [
              {active, true},       
              {verify, verify_none},
              {protocol, dtls},
              {versions, ['dtlsv1.2']},
              {certfile, "dtls-cert.pem"},
              {keyfile,  "dtls-key.pem"},
              {cb_info, {dtls_cb, dtls_data, dtls_closed, dtls_error}}
          ],
          {ok, CSock} = ssl:connect(Host, Port, Opts),
      
      

      when the "open" call in my dtls_cb module gets called I see these options

          dtls_cb:open(0, [{active,false},{mode,binary},{active,false},{mode,binary}])
      

      Note the the options are repeated twice, and they have nothing to do with the options that were passed to the ssl:connect statement

        Attachments

          Activity

            People

            Assignee:
            otp_team_ps Team PS
            Reporter:
            virtualairwaves Robert Swirsky
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated: