aboutsummaryrefslogtreecommitdiff
path: root/src/via-news-fix/via-dismiss.js
blob: 7c79e8386b7d47cea6efb88515fb93a5872a3392 (about) (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
/**
 * SPDX-License-Identifier: LicenseRef-GPL-3.0-or-later-WITH-js-exceptions
 *
 * Enable dismissing the prompt asking you to subscribe to Via.
 *
 * Copyright (C) 2022 Jacob K
 *
 * This program is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * This program is distributed in the hope that it will be useful,
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 * GNU General Public License for more details.
 *
 * As additional permission under GNU GPL version 3 section 7, you
 * may distribute forms of that code without the copy of the GNU
 * GPL normally required by section 4, provided you include this
 * license notice and, in case of non-source distribution, a URL
 * through which recipients can access the Corresponding Source.
 * If you modify file(s) with this exception, you may extend this
 * exception to your version of the file(s), but you are not
 * obligated to do so. If you do not wish to do so, delete this
 * exception statement from your version.
 *
 * As a special exception to the GPL, any HTML file which merely
 * makes function calls to this code, and for that purpose
 * includes it by reference shall be deemed a separate work for
 * copyright law purposes. If you modify this code, you may extend
 * this exception to your version of the code, but you are not
 * obligated to do so. If you do not wish to do so, delete this
 * exception statement from your version.
 *
 * You should have received a copy of the GNU General Public License
 * along with this program.  If not, see <https://www.gnu.org/licenses/>.
 */

/* Use with: https://via.news/*** */

/* add event listener to class "close" to delete ID "newsletter" in order to
make it possible to decline to subscribe (subscribing isn't possible though) */
document.getElementsByClassName("close")[0].addEventListener("click", function(){document.getElementById("newsletter").remove();});
09:54:03 +0200'>2021-08-14merge csp-PoCWojtek Kosior 2021-08-06Facilitate installation of scripts from the repositoryWojtek Kosior This commit includes: * removal of page_info_server * running of storage client in popup context * extraction of some common CSS to a separate file * extraction of scripts import view to a separate file * addition of a facility to conveniently clone complex structures from DOM (in DOM_helpers.js) * addition of hydrilla repo url to default settings * other minor changes and of course changes related to the actual installation of scripts from the repo 2021-08-04make settings_query.js use storage object passed as an argumentWojtek Kosior 2021-08-02[UNTESTED- will test] Add filtering for http-equiv CSP headersjahoti 2021-07-27validate settings on importWojtek Kosior 2021-07-26provide a facility to sanitize externally-obtained JSONWojtek Kosior 2021-07-26Fix some bugs in the refined CSP handlingjahoti 2021-07-26Remove unnecessary imports of url_item and add a CSP header-parsing functionjahoti The parsing function isn't used yet; however, it will eventually be as a less destructive alternative to handling headers as indivisible units. 2021-07-23extract observables implementation from storage.jsWojtek Kosior 2021-07-21add ability to query page content from repo and display it in the popupWojtek Kosior 2021-07-21store repository URLs in settingsWojtek Kosior 2021-07-20Merge rebranding to "Hachette"Wojtek Kosior 2021-07-20fix page info server bugsWojtek Kosior 2021-07-20Merge commit 'ecb787046271de708b94da70240713e725299d86'Wojtek Kosior 2021-07-19Refer to the extension consistently as "Hachette" and remove TODOS.orgjahoti from the copyright file 2021-07-18Streamline and harden unique values/settingsjahoti The base URL is now included in the settings. The unique value no longer uses it directly, as it is included by virtue of the settings; however, the number of full hours since the epoch (UTC) is now incorporated. 2021-07-17Revamp signatures and break header caching on FFjahoti Signatures, instead of consisting of the secure salt followed by the unique value generated from the URL, are now the unique value generated from the policy value (which will follow them) succeeded by the URL. CSP headers are now _always_ cleared on FF, regardless of whether the page is whitelisted or not. This means whitelisting takes effect on page reload, rather than only when caching occurs. However, it obviously presents security issues; refinment will occur in a future commit. 2021-07-16Use URL-based policy smugglingjahoti Increase the power of URL-based smuggling by making it (effectively) compulsory in all cases and adapting a <salt><unique value><JSON-encoded settings> structure. While the details still need to be worked out, the potential for future expansion is there. 2021-07-12Stop using the nonce consistently for a URLjahoti Nonces are now randomly generated, either in the page (for non-HTTP(S) pages) or by a background module which stores them by tab and frame IDs. In order to support the increased variance in nonce-generating methods and allow them to be loaded from the background, handle_page_actions is now invoked separately according to (non-)blocking mechanism. 2021-07-11Integrate browser.js into exports_init.js, and streamline the resultjahoti 2021-07-06show some settings of the current page in the popupWojtek Kosior 2021-07-02move parsing of url with targets to misc.jsWojtek Kosior 2021-06-30refactor 3 miscellaneous fnctionalities to a their single own fileWojtek Kosior 2021-06-30emply an sh-based build system; make some changes to blockingWojtek Kosior 2021-06-25gather all copyright info in 'copyright' fileWojtek Kosior 2021-06-14change licensesWojtek Kosior 2021-05-13make extension work under IceCat 60Wojtek Kosior 2021-05-12rename "bundles" to "bags"Wojtek Kosior 2021-05-12use unique hashes when smuggling whitelist settingWojtek Kosior 2021-05-12stop using js modulesWojtek Kosior 2021-05-10initial commitWojtek Kosior