Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
jami-daemon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
savoirfairelinux
jami-daemon
Commits
4a8a06b5
Commit
4a8a06b5
authored
14 years ago
by
Alexandre Savard
Browse files
Options
Downloads
Patches
Plain Diff
[#4243] Add documentation to AudioSrtpSession
parent
6d2b3eb0
No related branches found
No related tags found
No related merge requests found
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
sflphone-common/src/audio/audiortp/AudioSrtpSession.h
+46
-0
46 additions, 0 deletions
sflphone-common/src/audio/audiortp/AudioSrtpSession.h
with
46 additions
and
0 deletions
sflphone-common/src/audio/audiortp/AudioSrtpSession.h
+
46
−
0
View file @
4a8a06b5
...
@@ -78,30 +78,74 @@ class AudioSrtpSession : public ost::SymmetricRTPSession, public AudioRtpSession
...
@@ -78,30 +78,74 @@ class AudioSrtpSession : public ost::SymmetricRTPSession, public AudioRtpSession
{
{
public:
public:
/**
* Constructor for this rtp session
*/
AudioSrtpSession
(
ManagerImpl
*
manager
,
SIPCall
*
sipcall
);
AudioSrtpSession
(
ManagerImpl
*
manager
,
SIPCall
*
sipcall
);
/**
* Used to get sdp crypto header to be included in sdp session. This
* method must be called befor setRemoteCryptoInfo in case of an
* outgoing call or after in case of an outgoing call.
*/
std
::
vector
<
std
::
string
>
getLocalCryptoInfo
(
void
);
std
::
vector
<
std
::
string
>
getLocalCryptoInfo
(
void
);
/**
* Set remote crypto header from incoming sdp offer
*/
void
setRemoteCryptoInfo
(
sfl
::
SdesNegotiator
&
nego
);
void
setRemoteCryptoInfo
(
sfl
::
SdesNegotiator
&
nego
);
/**
* Init local crypto context for outgoing data
* this method must be called before sending first Invite request
* with SDP offer.
*/
void
initLocalCryptoInfo
(
void
);
void
initLocalCryptoInfo
(
void
);
private:
private:
/**
* Init local master key according to current crypto context
* as defined in SdesNegotiator.h
*/
void
initializeLocalMasterKey
(
void
);
void
initializeLocalMasterKey
(
void
);
/**
* Init local master salt according to current crypto context
* as defined in SdesNegotiator.h
*/
void
initializeLocalMasterSalt
(
void
);
void
initializeLocalMasterSalt
(
void
);
/**
* Init remote crypto context in audio srtp session. This method
* must be called after unBase64ConcatenatedKeys.
*/
void
initializeRemoteCryptoContext
(
void
);
void
initializeRemoteCryptoContext
(
void
);
/**
* Init local crypto context in audio srtp session. Make sure remote
* crypto context is set before calling this method for incoming calls.
*/
void
initializeLocalCryptoContext
(
void
);
void
initializeLocalCryptoContext
(
void
);
/**
* Used to generate local keys to be included in SDP offer/answer.
*/
std
::
string
getBase64ConcatenatedKeys
();
std
::
string
getBase64ConcatenatedKeys
();
/**
* Used to retreive keys from base64 serialization
*/
void
unBase64ConcatenatedKeys
(
std
::
string
base64keys
);
void
unBase64ConcatenatedKeys
(
std
::
string
base64keys
);
/**
* Encode input data as base64
*/
char
*
encodeBase64
(
unsigned
char
*
input
,
int
length
);
char
*
encodeBase64
(
unsigned
char
*
input
,
int
length
);
/**
* Decode base64 data
*/
char
*
decodeBase64
(
unsigned
char
*
input
,
int
length
,
int
*
length_out
);
char
*
decodeBase64
(
unsigned
char
*
input
,
int
length
,
int
*
length_out
);
/** Default local crypto suite is AES_CM_128_HMAC_SHA1_80*/
/** Default local crypto suite is AES_CM_128_HMAC_SHA1_80*/
...
@@ -130,8 +174,10 @@ class AudioSrtpSession : public ost::SymmetricRTPSession, public AudioRtpSession
...
@@ -130,8 +174,10 @@ class AudioSrtpSession : public ost::SymmetricRTPSession, public AudioRtpSession
/** remote master salt length in byte */
/** remote master salt length in byte */
int
_remoteMasterSaltLength
;
int
_remoteMasterSaltLength
;
/** Remote srtp crypto context to be set into incoming data queue. */
ost
::
CryptoContext
*
_remoteCryptoCtx
;
ost
::
CryptoContext
*
_remoteCryptoCtx
;
/** Local srtp crypto context to be set into outgoing data queue. */
ost
::
CryptoContext
*
_localCryptoCtx
;
ost
::
CryptoContext
*
_localCryptoCtx
;
};
};
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment