var { XPCOMUtils } = ChromeUtils.importESModule( "resource://gre/modules/XPCOMUtils.sys.mjs"
);
try { // In the context of xpcshell tests, there won't be a default AppInfo // eslint-disable-next-line mozilla/use-services
Cc["@mozilla.org/xre/app-info;1"].getService(Ci.nsIXULAppInfo);
} catch (ex) { // Make sure to provide the right OS so crypto loads the right binaries var OS = "XPCShell"; if (mozinfo.os == "win") {
OS = "WINNT";
} elseif (mozinfo.os == "mac") {
OS = "Darwin";
} else {
OS = "Linux";
}
function base64UrlDecode(s) {
s = s.replace(/-/g, "+");
s = s.replace(/_/g, "/");
// Replace padding if it was stripped by the sender. // See http://tools.ietf.org/html/rfc4648#section-4 switch (s.length % 4) { case0: break; // No pad chars in this case case2:
s += "=="; break; // Two pad chars case3:
s += "="; break; // One pad char default: thrownew Error("Illegal base64url string!");
}
// With correct padding restored, apply the standard base64 decoder
return atob(s);
}
/** *Printsomedebugmessagetotheconsole.Allargumentswillbeprinted, *separatedbyspaces. * *@param[arg0,arg1,arg2,...] *Anynumberofargumentstoprintout *Usage:_("HelloWorld")->prints"HelloWorld" *Usage:_(1,2,3)->prints"123"
*/ var _ = function () {
print(Array.from(arguments).join(" "));
};
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.