nassh: initial ssh:// uri handler prompt flashes when using a relay host |
||||
Issue descriptionto reproduce: (1) go to chrome://settings/handlers and delete ssh handlers (2) load secure shell (3) connect to a system via a relay (4) watch ssh:// prompt pop up briefly, but then be dismissed by the redirect/page reload due to the relay
,
Nov 11 2017
i remember now why it's this way -- navigator.registerProtocolHandler works only if it's part of a user generated event code path. the connect dialog is the last place where that signal exists so that's where we make the register call.
nassh.ConnectDialog.prototype.connect = function(name, argv) {
this.maybeCopyPlaceholders_();
this.save();
// Since the user has initiated this connection, register the protocol.
nassh.registerProtocolHandler();
var items = {
'/nassh/connectDialog/lastProfileId': this.currentProfileRecord_.id
};
chrome.storage.local.set(items);
if (this.form_.checkValidity())
this.postMessage('connectToProfile', [this.currentProfileRecord_.id]);
};
after we post the message, the main window gets that event and starts the actual connection, but Chrome doesn't have any of that tagged as user generated.
this will probably have to wait until we rework the connection dialog flow in issue 362725.
,
Jan 9
i've filed b/122463446 to track adding support for method=direct to the Google relay servers. once we have that, we don't need the redirect to the relay page anymore, so the terminal won't be reloaded at all, and the prompt would stay in place. along those lines, it's not dependent upon the iframe change in the connection dialog. i thought there might be another bug related to reworking the connect/relay flow, but that prob was fixed enough for the ssh-fe code (i.e. https://chromium-review.googlesource.com/c/1390222).
,
Jan 9
|
||||
►
Sign in to add a comment |
||||
Comment 1 by vapier@chromium.org
, May 25 2017