RequestPolicy/tractest — Issue #48: Link click is blocked if the link target contains IDN
Author: jsamuel
Created: 2011-12-22 02:33:07+00:00
State: open
Labels: extension

For example, click .
RequestPolicy will block the request to xn--lhr645fjve.jp.
I've found the following methods in nsIRequestPolicy broke the non-ascii chars.
11	void registerHistoryRequest(in ACString destinationUri);
12	void registerFormSubmitted(in ACString originUri, in ACString destinationUri);
13	void registerLinkClicked(in ACString originUri, in ACString destinationUri);
The parameter type should be AString rather than ACString. ACString will cripple the non-ascii chars from JavaScript caller.
In general, XPCOM components written in JavaScript should use AString because JavaScript strings are encoded as UTF-16.