Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
BC
public
liblinphone
Commits
72f4bdd9
Commit
72f4bdd9
authored
Dec 15, 2011
by
jehan
Browse files
fix usage of non default srtp key
parent
32b42a59
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
21 additions
and
6 deletions
+21
-6
.cproject
.cproject
+8
-0
coreapi/linphonecall.c
coreapi/linphonecall.c
+10
-3
coreapi/offeranswer.c
coreapi/offeranswer.c
+2
-2
oRTP
oRTP
+1
-1
No files found.
.cproject
View file @
72f4bdd9
...
...
@@ -238,6 +238,14 @@
<useDefaultCommand>
true
</useDefaultCommand>
<runAllBuilders>
true
</runAllBuilders>
</target>
<target
name=
"doc"
path=
"mediastreamer2/help"
targetID=
"org.eclipse.cdt.build.MakeTargetBuilder"
>
<buildCommand>
make
</buildCommand>
<buildArguments/>
<buildTarget>
all
</buildTarget>
<stopOnError>
true
</stopOnError>
<useDefaultCommand>
true
</useDefaultCommand>
<runAllBuilders>
true
</runAllBuilders>
</target>
</buildTargets>
</storageModule>
</cconfiguration>
...
...
coreapi/linphonecall.c
View file @
72f4bdd9
...
...
@@ -1039,7 +1039,15 @@ static bool_t linphone_call_sound_resources_available(LinphoneCall *call){
return
!
linphone_core_is_in_conference
(
lc
)
&&
(
current
==
NULL
||
current
==
call
);
}
static
int
find_crypto_index_from_tag
(
SalSrtpCryptoAlgo
crypto
[],
unsigned
char
tag
)
{
int
i
;
for
(
i
=
0
;
i
<
SAL_CRYPTO_ALGO_MAX
;
i
++
)
{
if
(
crypto
[
i
].
tag
==
tag
)
{
return
i
;
}
}
return
-
1
;
}
static
void
linphone_call_start_audio_stream
(
LinphoneCall
*
call
,
const
char
*
cname
,
bool_t
muted
,
bool_t
send_ringbacktone
,
bool_t
use_arc
){
LinphoneCore
*
lc
=
call
->
core
;
int
jitt_comp
=
lc
->
rtp_conf
.
audio_jitt_comp
;
...
...
@@ -1130,11 +1138,10 @@ static void linphone_call_start_audio_stream(LinphoneCall *call, const char *cna
if
(
stream
->
proto
==
SalProtoRtpSavp
)
{
const
SalStreamDescription
*
local_st_desc
=
sal_media_description_find_stream
(
call
->
localdesc
,
SalProtoRtpSavp
,
SalAudio
);
audio_stream_enable_strp
(
call
->
audiostream
,
stream
->
crypto
[
0
].
algo
,
local_st_desc
->
crypto
[
0
].
master_key
,
local_st_desc
->
crypto
[
find_crypto_index_from_tag
(
local_st_desc
->
crypto
,
stream
->
crypto
[
0
].
tag
)
].
master_key
,
stream
->
crypto
[
0
].
master_key
);
call
->
audiostream_encrypted
=
TRUE
;
}
else
call
->
audiostream_encrypted
=
FALSE
;
...
...
coreapi/offeranswer.c
View file @
72f4bdd9
...
...
@@ -142,8 +142,8 @@ static bool_t match_crypto_algo(const SalSrtpCryptoAlgo* local, const SalSrtpCry
strncpy
(
result
->
master_key
,
local
[
j
].
master_key
,
41
);
result
->
tag
=
local
[
j
].
tag
;
}
else
{
strncpy
(
result
->
master_key
,
remote
[
j
].
master_key
,
41
);
result
->
tag
=
remote
[
j
].
tag
;
strncpy
(
result
->
master_key
,
remote
[
i
].
master_key
,
41
);
result
->
tag
=
remote
[
i
].
tag
;
}
result
->
master_key
[
40
]
=
'\0'
;
return
TRUE
;
...
...
oRTP
@
758150c3
Subproject commit
070d30dd75940b8c2e5898246437e213a47e834c
Subproject commit
758150c3cd0f5a3a7a087247d6ff2dd198435fe7
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment