mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 05:11:16 +00:00
Bug 1247619 - add console warning about OAuth for STUN not yet supported. r=jesup,smaug
MozReview-Commit-ID: L0nViIWiIDn --HG-- extra : rebase_source : 3d463e85c811426384a758dca3b0a82370c22099
This commit is contained in:
parent
2f131341dd
commit
c4ea91fa82
@ -586,6 +586,13 @@ RTCPeerConnection.prototype = {
|
|||||||
throw new this._win.DOMException(msg + " - missing credential: " + urlStr,
|
throw new this._win.DOMException(msg + " - missing credential: " + urlStr,
|
||||||
"InvalidAccessError");
|
"InvalidAccessError");
|
||||||
}
|
}
|
||||||
|
if (server.credentialType != "password") {
|
||||||
|
this.logWarning("RTCConfiguration TURN credentialType \""+
|
||||||
|
server.credentialType +
|
||||||
|
"\" is not yet implemented. Treating as password."+
|
||||||
|
" https://bugzil.la/1247616",
|
||||||
|
null, 0);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
else if (!(url.scheme in { stun:1, stuns:1 })) {
|
else if (!(url.scheme in { stun:1, stuns:1 })) {
|
||||||
throw new this._win.DOMException(msg + " - improper scheme: " + url.scheme,
|
throw new this._win.DOMException(msg + " - improper scheme: " + url.scheme,
|
||||||
|
@ -7,11 +7,17 @@
|
|||||||
* http://dev.w3.org/2011/webrtc/editor/webrtc.html#idl-def-RTCConfiguration
|
* http://dev.w3.org/2011/webrtc/editor/webrtc.html#idl-def-RTCConfiguration
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
enum RTCIceCredentialType {
|
||||||
|
"password",
|
||||||
|
"token"
|
||||||
|
};
|
||||||
|
|
||||||
dictionary RTCIceServer {
|
dictionary RTCIceServer {
|
||||||
(DOMString or sequence<DOMString>) urls;
|
(DOMString or sequence<DOMString>) urls;
|
||||||
DOMString url; //deprecated
|
DOMString url; //deprecated
|
||||||
DOMString? credential = null;
|
DOMString username;
|
||||||
DOMString? username = null;
|
DOMString credential;
|
||||||
|
RTCIceCredentialType credentialType = "password";
|
||||||
};
|
};
|
||||||
|
|
||||||
enum RTCIceTransportPolicy {
|
enum RTCIceTransportPolicy {
|
||||||
|
@ -663,8 +663,8 @@ PeerConnectionConfiguration::AddIceServer(const RTCIceServer &aServer)
|
|||||||
port = (isStuns || isTurns)? 5349 : 3478;
|
port = (isStuns || isTurns)? 5349 : 3478;
|
||||||
|
|
||||||
if (isTurn || isTurns) {
|
if (isTurn || isTurns) {
|
||||||
NS_ConvertUTF16toUTF8 credential(aServer.mCredential);
|
NS_ConvertUTF16toUTF8 credential(aServer.mCredential.Value());
|
||||||
NS_ConvertUTF16toUTF8 username(aServer.mUsername);
|
NS_ConvertUTF16toUTF8 username(aServer.mUsername.Value());
|
||||||
|
|
||||||
if (!addTurnServer(host.get(), port,
|
if (!addTurnServer(host.get(), port,
|
||||||
username.get(),
|
username.get(),
|
||||||
|
Loading…
Reference in New Issue
Block a user