{"id":61464,"library":"libsrtp","title":"libSRTP","description":"This package provides an implementation of the Secure Real-time Transport Protocol (SRTP), the Universal Security Transform (UST), and a supporting cryptographic kernel.","status":"active","version":"2.7.0","language":"cpp","source_language":null,"source_url":null,"tags":["srtp","security","rtp","crypto","real-time"],"install":[{"cmd":"vcpkg install libsrtp","lang":"bash","label":"vcpkg"},{"cmd":"# CMakeLists.txt\nfind_package(libsrtp CONFIG REQUIRED)\ntarget_link_libraries(main PRIVATE libsrtp2::libsrtp2)","lang":"cmake","label":"CMake"}],"dependencies":[],"imports":[{"symbol":"srtp2/srtp.h","correct":"#include <srtp2/srtp.h>"}],"quickstart":{"code":"#include <srtp2/srtp.h>\n#include <cstring>\n\nint main() {\n    srtp_init();\n    srtp_policy_t policy;\n    memset(&policy, 0, sizeof(policy));\n    srtp_crypto_policy_set_aes_cm_128_hmac_sha1_80(&policy.rtp);\n    srtp_crypto_policy_set_aes_cm_128_hmac_sha1_80(&policy.rtcp);\n    policy.ssrc.type = ssrc_any_inbound;\n    srtp_ctx_t* session;\n    srtp_create(&session, &policy);\n    // Use session to protect/unprotect RTP packets\n    srtp_dealloc(session);\n    srtp_shutdown();\n    return 0;\n}","lang":"cpp","description":"Initialize libSRTP, create a session with AES-128 CM HMAC-SHA1-80 policy, and clean up."},"warnings":[{"fix":"Always generate cryptographically random keys and use unique master keys per session.","message":"libSRTP requires careful key management; using weak keys or reusing keys can break security.","severity":"breaking","affected_versions":"*"}],"env_vars":null,"search_vec":"'crypto':29 'cryptograph':24 'implement':6 'kernel':25 'libsrtp':1 'packag':3 'protocol':14 'provid':4 'real':11,31 'real-tim':10,30 'rtp':28 'secur':9,18,27 'srtp':15,26 'support':23 'time':12,32 'transform':19 'transport':13 'univers':17 'ust':20","created_at":"2026-06-17T04:51:32.297160+00:00","updated_at":"2026-06-17T04:51:32.297160+00:00","problems":[],"ecosystem":"vcpkg","meta_description":null,"install_score":null,"quickstart_score":null,"quickstart_tag":null,"pypi_latest":null,"cli_name":null,"cli_version":null,"type":"library","homepage":null,"github":null,"docs":null,"changelog":null,"pypi":null,"npm":null,"openapi_spec":null,"status_page":null,"smithery":null,"categories":["crypto","networking"],"base_url":null,"auth_type":null,"provenance":{"verified_status":null,"verified_at":null,"last_verified":"2026-06-17","next_check":"2026-12-14","install_tag":null}}