mirror of
https://github.com/mollyim/webrtc.git
synced 2025-05-17 23:57:59 +01:00
loosen ice-ufrag/ice-pwd ice-char restrictions
Loosen the restrictions for ice-char by allowing '-' and '='. Being spec-compliant breaks interoperability. The spec-behaviour will be restored with a notice period. BUG=chromium:1053756,chromium:1044521 No-Try: True Change-Id: I880babd0869302bd713912ddfcfa48866fad32c1 Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/168820 Commit-Queue: Steve Anton <steveanton@webrtc.org> Reviewed-by: Steve Anton <steveanton@webrtc.org> Reviewed-by: Harald Alvestrand <hta@webrtc.org> Cr-Commit-Position: refs/heads/master@{#30560}
This commit is contained in:
parent
8041b651a3
commit
48e849f569
1 changed files with 11 additions and 0 deletions
|
@ -14,6 +14,7 @@
|
|||
#include "absl/strings/match.h"
|
||||
#include "p2p/base/p2p_constants.h"
|
||||
#include "rtc_base/arraysize.h"
|
||||
#include "rtc_base/logging.h"
|
||||
#include "rtc_base/strings/string_builder.h"
|
||||
|
||||
using webrtc::RTCError;
|
||||
|
@ -24,6 +25,16 @@ namespace cricket {
|
|||
namespace {
|
||||
|
||||
bool IsIceChar(char c) {
|
||||
// Note: '-' and '=' are *not* valid ice-chars but temporarily permitted
|
||||
// in order to allow external software to upgrade.
|
||||
if (c == '-' || c == '=') {
|
||||
RTC_LOG(LS_WARNING)
|
||||
<< "'-' and '=' are not valid ice-char and thus not permitted in "
|
||||
<< "ufrag or pwd. This is a protocol violation that is permitted "
|
||||
<< "for to allow upgrading but will be rejected in the future. "
|
||||
<< "See https://crbug.com/1053756";
|
||||
return true;
|
||||
}
|
||||
return absl::ascii_isalnum(c) || c == '+' || c == '/';
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue