MCPcopy Create free account
hub / github.com/apache/cloudstack / _handleSecurityReason

Method _handleSecurityReason

systemvm/agent/noVNC/core/rfb.js:1773–1802  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1771 }
1772
1773 _handleSecurityReason() {
1774 if (this._sock.rQwait("reason length", 4)) {
1775 return false;
1776 }
1777 const strlen = this._sock.rQshift32();
1778 let reason = "";
1779
1780 if (strlen > 0) {
1781 if (this._sock.rQwait("reason", strlen, 4)) { return false; }
1782 reason = this._sock.rQshiftStr(strlen);
1783 }
1784
1785 if (reason !== "") {
1786 this.dispatchEvent(new CustomEvent(
1787 "securityfailure",
1788 { detail: { status: this._securityStatus,
1789 reason: reason } }));
1790
1791 return this._fail("Security negotiation failed on " +
1792 this._securityContext +
1793 " (reason: " + reason + ")");
1794 } else {
1795 this.dispatchEvent(new CustomEvent(
1796 "securityfailure",
1797 { detail: { status: this._securityStatus } }));
1798
1799 return this._fail("Security negotiation failed on " +
1800 this._securityContext);
1801 }
1802 }
1803
1804 // authentication
1805 _negotiateXvpAuth() {

Callers 1

_initMsgMethod · 0.95

Calls 5

_failMethod · 0.95
rQwaitMethod · 0.80
rQshift32Method · 0.80
rQshiftStrMethod · 0.80
dispatchEventMethod · 0.80

Tested by

no test coverage detected