Project

General

Profile

« Previous | Next » 

Revision 1789f174

Added by koszko about 2 years ago

merge jahoti into master

View differences:

background/nonce_store.js
19 19
    console.log('Nonce for ' + code + ' ' + (update ? 'created/updated' : 'requested'));
20 20
    if (update)
21 21
        nonces[code] = gen_nonce();
22
    
22

  
23 23
    return nonces[code];
24 24
}
25 25

  
build.sh
194 194

  
195 195
main() {
196 196
    set_browser "$1"
197
    
197

  
198 198
    # placate importers of these, as they are exported by the yet-to-be-created exports_init.js
199 199
    EXPORTS__browser=exports_init.js
200 200
    EXPORTS__is_chrome=exports_init.js
content/main.js
18 18
 * IMPORT is_privileged_url
19 19
 * IMPORT sanitize_attributes
20 20
 * IMPORT mozilla_suppress_scripts
21
 * IMPORT browser
21 22
 * IMPORT is_chrome
22 23
 * IMPORT is_mozilla
23 24
 * IMPORT start_activity_info_server
......
134 135
	    port.onMessage.removeListener(nonce_capturer);
135 136
	    handle_page_actions(msg[1], port);
136 137
	};
137
	
138

  
138 139
	port.onMessage.addListener(nonce_capturer);
139
	
140

  
140 141
    } else if (is_whitelisted()) {
141 142
	/* do not block scripts at all; as a result, there is no need for a green-lighted nonce */
142 143
	handle_page_actions(null, port);
copyright
8 8

  
9 9
Files: build.sh
10 10
Copyright: 2021 Wojtek Kosior <koszko@koszko.org>
11
   2021 jahoti <jahoti@tilde.team>
11 12
License: CC0
12 13

  
13
Files: manifest.json common/misc.js content/main.js
14
Files: common/misc.js content/main.js
14 15
Copyright: 2021 Wojtek Kosior <koszko@koszko.org>
15 16
   2021 jahoti <jahoti@tilde.team>
16 17
License: GPL-3+-javascript or Alicense-1.0

Also available in: Unified diff