Thu, 04 Feb 2021 14:59:13 +0100
Web Browser: removed the Flash Cookie Manager because Flash is dead.
--- a/eric6.epj Thu Feb 04 14:38:33 2021 +0100 +++ b/eric6.epj Thu Feb 04 14:59:13 2021 +0100 @@ -758,7 +758,6 @@ "eric6/Preferences/ConfigurationPages/VcsPage.py", "eric6/Preferences/ConfigurationPages/ViewmanagerPage.py", "eric6/Preferences/ConfigurationPages/WebBrowserAppearancePage.py", - "eric6/Preferences/ConfigurationPages/WebBrowserFlashCookieManagerPage.py", "eric6/Preferences/ConfigurationPages/WebBrowserInterfacePage.py", "eric6/Preferences/ConfigurationPages/WebBrowserPage.py", "eric6/Preferences/ConfigurationPages/WebBrowserSpellCheckingPage.py", @@ -1411,13 +1410,6 @@ "eric6/WebBrowser/Feeds/FeedsDialog.py", "eric6/WebBrowser/Feeds/FeedsManager.py", "eric6/WebBrowser/Feeds/__init__.py", - "eric6/WebBrowser/FlashCookieManager/FlashCookie.py", - "eric6/WebBrowser/FlashCookieManager/FlashCookieManager.py", - "eric6/WebBrowser/FlashCookieManager/FlashCookieManagerDialog.py", - "eric6/WebBrowser/FlashCookieManager/FlashCookieNotification.py", - "eric6/WebBrowser/FlashCookieManager/FlashCookieReader.py", - "eric6/WebBrowser/FlashCookieManager/FlashCookieUtilities.py", - "eric6/WebBrowser/FlashCookieManager/__init__.py", "eric6/WebBrowser/GreaseMonkey/GreaseMonkeyAddScriptDialog.py", "eric6/WebBrowser/GreaseMonkey/GreaseMonkeyConfiguration/GreaseMonkeyConfigurationDialog.py", "eric6/WebBrowser/GreaseMonkey/GreaseMonkeyConfiguration/GreaseMonkeyConfigurationListDelegate.py", @@ -1945,7 +1937,6 @@ "eric6/Preferences/ConfigurationPages/VcsPage.ui", "eric6/Preferences/ConfigurationPages/ViewmanagerPage.ui", "eric6/Preferences/ConfigurationPages/WebBrowserAppearancePage.ui", - "eric6/Preferences/ConfigurationPages/WebBrowserFlashCookieManagerPage.ui", "eric6/Preferences/ConfigurationPages/WebBrowserInterfacePage.ui", "eric6/Preferences/ConfigurationPages/WebBrowserPage.ui", "eric6/Preferences/ConfigurationPages/WebBrowserSpellCheckingPage.ui", @@ -2041,7 +2032,6 @@ "eric6/WebBrowser/Feeds/FeedEditDialog.ui", "eric6/WebBrowser/Feeds/FeedsDialog.ui", "eric6/WebBrowser/Feeds/FeedsManager.ui", - "eric6/WebBrowser/FlashCookieManager/FlashCookieManagerDialog.ui", "eric6/WebBrowser/GreaseMonkey/GreaseMonkeyAddScriptDialog.ui", "eric6/WebBrowser/GreaseMonkey/GreaseMonkeyConfiguration/GreaseMonkeyConfigurationDialog.ui", "eric6/WebBrowser/GreaseMonkey/GreaseMonkeyConfiguration/GreaseMonkeyConfigurationScriptInfoDialog.ui", @@ -2392,22 +2382,38 @@ "PROJECTTYPESPECIFICDATA": {}, "CHECKERSPARMS": { "Pep8Checker": { - "AnnotationsChecker": { - "MaximumComplexity": 3, - "MinimumCoverage": 75 - }, + "EnabledCheckerCategories": "C, D, E, M, N, W", + "ExcludeFiles": "*/ThirdParty/*, */coverage/*, */Ui_*.py, */Examples/*, */*_rc.py,*/pycodestyle.py,*/pyflakes/checker.py,*/mccabe.py,*/eradicate.py", + "ExcludeMessages": "C101,E265,E266,E305,E402,M201,M301,M302,M303,M304,M305,M306,M307,M308,M311,M312,M313,M314,M315,M321,M701,M702,M811,M834,N802,N803,N807,N808,N821,W293,W504", + "IncludeMessages": "", + "RepeatMessages": true, + "FixCodes": "", + "NoFixCodes": "E501", + "FixIssues": false, + "ShowIgnored": false, + "MaxLineLength": 79, + "MaxDocLineLength": 79, "BlankLines": [ 2, 1 ], + "HangClosing": false, + "DocstringType": "eric", + "MaxCodeComplexity": 10, + "LineComplexity": 25, + "LineComplexityScore": 10, + "ValidEncodings": "latin-1, utf-8", + "CopyrightMinFileSize": 0, + "CopyrightAuthor": "", + "FutureChecker": "", "BuiltinsChecker": { - "bytes": [ + "str": [ "unicode" ], "chr": [ "unichr" ], - "str": [ + "bytes": [ "unicode" ] }, @@ -2429,26 +2435,11 @@ "- " ] }, - "CopyrightAuthor": "", - "CopyrightMinFileSize": 0, - "DocstringType": "eric", - "EnabledCheckerCategories": "C, D, E, M, N, W", - "ExcludeFiles": "*/ThirdParty/*, */coverage/*, */Ui_*.py, */Examples/*, */*_rc.py,*/pycodestyle.py,*/pyflakes/checker.py,*/mccabe.py,*/eradicate.py", - "ExcludeMessages": "C101,E265,E266,E305,E402,M201,M301,M302,M303,M304,M305,M306,M307,M308,M311,M312,M313,M314,M315,M321,M701,M702,M811,M834,N802,N803,N807,N808,N821,W293,W504", - "FixCodes": "", - "FixIssues": false, - "FutureChecker": "", - "HangClosing": false, - "IncludeMessages": "", - "LineComplexity": 25, - "LineComplexityScore": 10, - "MaxCodeComplexity": 10, - "MaxDocLineLength": 79, - "MaxLineLength": 79, - "NoFixCodes": "E501", - "RepeatMessages": true, + "AnnotationsChecker": { + "MinimumCoverage": 75, + "MaximumComplexity": 3 + }, "SecurityChecker": { - "CheckTypedException": false, "HardcodedTmpDirectories": [ "/tmp", "/var/tmp", @@ -2472,13 +2463,12 @@ ], "WeakKeySizeDsaHigh": "1024", "WeakKeySizeDsaMedium": "2048", + "WeakKeySizeRsaHigh": "1024", + "WeakKeySizeRsaMedium": "2048", "WeakKeySizeEcHigh": "160", "WeakKeySizeEcMedium": "224", - "WeakKeySizeRsaHigh": "1024", - "WeakKeySizeRsaMedium": "2048" - }, - "ShowIgnored": false, - "ValidEncodings": "latin-1, utf-8" + "CheckTypedException": false + } }, "SyntaxChecker": { "ExcludeFiles": "*/coverage/*, */ThirdParty/*, */Examples/*"
--- a/eric6/Documentation/Source/eric6.Preferences.ConfigurationPages.WebBrowserFlashCookieManagerPage.html Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,129 +0,0 @@ -<!DOCTYPE html> -<html><head> -<title>eric6.Preferences.ConfigurationPages.WebBrowserFlashCookieManagerPage</title> -<meta charset="UTF-8"> -<style> -body { - background: #EDECE6; - margin: 0em 1em 10em 1em; - color: black; -} - -h1 { color: white; background: #85774A; } -h2 { color: white; background: #85774A; } -h3 { color: white; background: #9D936E; } -h4 { color: white; background: #9D936E; } - -a { color: #BA6D36; } - -</style> -</head> -<body> -<a NAME="top" ID="top"></a> -<h1>eric6.Preferences.ConfigurationPages.WebBrowserFlashCookieManagerPage</h1> - -<p> -Module implementing the Flash Cookies Manager configuration page. -</p> -<h3>Global Attributes</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Classes</h3> - -<table> - -<tr> -<td><a href="#WebBrowserFlashCookieManagerPage">WebBrowserFlashCookieManagerPage</a></td> -<td>Class implementing the Flash Cookies Manager configuration page.</td> -</tr> -</table> -<h3>Functions</h3> - -<table> - -<tr> -<td><a href="#create">create</a></td> -<td>Module function to create the configuration page.</td> -</tr> -</table> -<hr /> -<hr /> -<a NAME="WebBrowserFlashCookieManagerPage" ID="WebBrowserFlashCookieManagerPage"></a> -<h2>WebBrowserFlashCookieManagerPage</h2> - -<p> - Class implementing the Flash Cookies Manager configuration page. -</p> -<h3>Derived from</h3> -ConfigurationPageBase, Ui_WebBrowserFlashCookieManagerPage -<h3>Class Attributes</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Class Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Methods</h3> - -<table> - -<tr> -<td><a href="#WebBrowserFlashCookieManagerPage.__init__">WebBrowserFlashCookieManagerPage</a></td> -<td>Constructor</td> -</tr> -<tr> -<td><a href="#WebBrowserFlashCookieManagerPage.save">save</a></td> -<td>Public slot to save the Flash Cookies Manager configuration.</td> -</tr> -</table> -<h3>Static Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> - -<a NAME="WebBrowserFlashCookieManagerPage.__init__" ID="WebBrowserFlashCookieManagerPage.__init__"></a> -<h4>WebBrowserFlashCookieManagerPage (Constructor)</h4> -<b>WebBrowserFlashCookieManagerPage</b>(<i></i>) - -<p> - Constructor -</p> -<a NAME="WebBrowserFlashCookieManagerPage.save" ID="WebBrowserFlashCookieManagerPage.save"></a> -<h4>WebBrowserFlashCookieManagerPage.save</h4> -<b>save</b>(<i></i>) - -<p> - Public slot to save the Flash Cookies Manager configuration. -</p> -<div align="right"><a href="#top">Up</a></div> -<hr /> -<hr /> -<a NAME="create" ID="create"></a> -<h2>create</h2> -<b>create</b>(<i>dlg</i>) - -<p> - Module function to create the configuration page. -</p> -<dl> - -<dt><i>dlg</i></dt> -<dd> -reference to the configuration dialog -</dd> -</dl> -<dl> -<dt>Return:</dt> -<dd> -reference to the instantiated page (ConfigurationPageBase) -</dd> -</dl> -<div align="right"><a href="#top">Up</a></div> -<hr /> -</body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.WebBrowser.FlashCookieManager.FlashCookie.html Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,121 +0,0 @@ -<!DOCTYPE html> -<html><head> -<title>eric6.WebBrowser.FlashCookieManager.FlashCookie</title> -<meta charset="UTF-8"> -<style> -body { - background: #EDECE6; - margin: 0em 1em 10em 1em; - color: black; -} - -h1 { color: white; background: #85774A; } -h2 { color: white; background: #85774A; } -h3 { color: white; background: #9D936E; } -h4 { color: white; background: #9D936E; } - -a { color: #BA6D36; } - -</style> -</head> -<body> -<a NAME="top" ID="top"></a> -<h1>eric6.WebBrowser.FlashCookieManager.FlashCookie</h1> - -<p> -Module implementing the Flash cookie class. -</p> -<h3>Global Attributes</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Classes</h3> - -<table> - -<tr> -<td><a href="#FlashCookie">FlashCookie</a></td> -<td>Class implementing the Flash cookie.</td> -</tr> -</table> -<h3>Functions</h3> - -<table> -<tr><td>None</td></tr> -</table> -<hr /> -<hr /> -<a NAME="FlashCookie" ID="FlashCookie"></a> -<h2>FlashCookie</h2> - -<p> - Class implementing the Flash cookie. -</p> -<h3>Derived from</h3> -object -<h3>Class Attributes</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Class Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Methods</h3> - -<table> - -<tr> -<td><a href="#FlashCookie.__init__">FlashCookie</a></td> -<td>Constructor</td> -</tr> -<tr> -<td><a href="#FlashCookie.__eq__">__eq__</a></td> -<td>Special method to compare to another Flash cookie.</td> -</tr> -</table> -<h3>Static Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> - -<a NAME="FlashCookie.__init__" ID="FlashCookie.__init__"></a> -<h4>FlashCookie (Constructor)</h4> -<b>FlashCookie</b>(<i></i>) - -<p> - Constructor -</p> -<a NAME="FlashCookie.__eq__" ID="FlashCookie.__eq__"></a> -<h4>FlashCookie.__eq__</h4> -<b>__eq__</b>(<i>other</i>) - -<p> - Special method to compare to another Flash cookie. -</p> -<dl> - -<dt><i>other</i> (FlashCookie)</dt> -<dd> -reference to the other Flash cookie -</dd> -</dl> -<dl> -<dt>Return:</dt> -<dd> -flag indicating equality of the two cookies -</dd> -</dl> -<dl> -<dt>Return Type:</dt> -<dd> -bool -</dd> -</dl> -<div align="right"><a href="#top">Up</a></div> -<hr /> -</body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.WebBrowser.FlashCookieManager.FlashCookieManager.html Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,462 +0,0 @@ -<!DOCTYPE html> -<html><head> -<title>eric6.WebBrowser.FlashCookieManager.FlashCookieManager</title> -<meta charset="UTF-8"> -<style> -body { - background: #EDECE6; - margin: 0em 1em 10em 1em; - color: black; -} - -h1 { color: white; background: #85774A; } -h2 { color: white; background: #85774A; } -h3 { color: white; background: #9D936E; } -h4 { color: white; background: #9D936E; } - -a { color: #BA6D36; } - -</style> -</head> -<body> -<a NAME="top" ID="top"></a> -<h1>eric6.WebBrowser.FlashCookieManager.FlashCookieManager</h1> - -<p> -Module implementing the Flash cookie manager. -</p> -<h3>Global Attributes</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Classes</h3> - -<table> - -<tr> -<td><a href="#FlashCookieManager">FlashCookieManager</a></td> -<td>Class implementing the Flash cookie manager object.</td> -</tr> -</table> -<h3>Functions</h3> - -<table> -<tr><td>None</td></tr> -</table> -<hr /> -<hr /> -<a NAME="FlashCookieManager" ID="FlashCookieManager"></a> -<h2>FlashCookieManager</h2> - -<p> - Class implementing the Flash cookie manager object. -</p> -<h3>Derived from</h3> -QObject -<h3>Class Attributes</h3> - -<table> -<tr><td>RefreshInterval</td></tr> -</table> -<h3>Class Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Methods</h3> - -<table> - -<tr> -<td><a href="#FlashCookieManager.__init__">FlashCookieManager</a></td> -<td>Constructor</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.__autoRefresh">__autoRefresh</a></td> -<td>Private slot to refresh the list of cookies.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.__extractOriginFrom">__extractOriginFrom</a></td> -<td>Private method to extract the cookie origin given its file name.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.__insertFlashCookie">__insertFlashCookie</a></td> -<td>Private method to insert a Flash cookie into the cache.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.__isBlacklisted">__isBlacklisted</a></td> -<td>Private method to check for a blacklisted cookie.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.__isWhitelisted">__isWhitelisted</a></td> -<td>Private method to check for a whitelisted cookie.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.__loadFlashCookies">__loadFlashCookies</a></td> -<td>Private slot to load the Flash cookies to be cached.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.__loadFlashCookiesFromPath">__loadFlashCookiesFromPath</a></td> -<td>Private slot to load the Flash cookies from a path.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.__removeAllButWhitelisted">__removeAllButWhitelisted</a></td> -<td>Private method to remove all non-whitelisted cookies.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.__sharedObjectDirName">__sharedObjectDirName</a></td> -<td>Private slot to determine the path of the shared data objects.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.__startStopTimer">__startStopTimer</a></td> -<td>Private slot to start or stop the auto refresh timer.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.clearCache">clearCache</a></td> -<td>Public method to clear the list of cached Flash cookies.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.clearNewOrigins">clearNewOrigins</a></td> -<td>Public method to clear the list of newly detected Flash cookies.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.flashCookies">flashCookies</a></td> -<td>Public method to get the list of cached Flash cookies.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.flashPlayerDataPath">flashPlayerDataPath</a></td> -<td>Public method to get the Flash Player data path.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.newCookiesList">newCookiesList</a></td> -<td>Public method to get the list of newly detected Flash cookies.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.preferencesChanged">preferencesChanged</a></td> -<td>Public slot to handle a change of preferences.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.removeAllCookies">removeAllCookies</a></td> -<td>Public method to remove all flash cookies.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.removeCookie">removeCookie</a></td> -<td>Public method to remove a cookie of the list of cached cookies.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.setFlashCookies">setFlashCookies</a></td> -<td>Public method to set the list of cached Flash cookies.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.showFlashCookieManagerDialog">showFlashCookieManagerDialog</a></td> -<td>Public method to show the Flash cookies management dialog.</td> -</tr> -<tr> -<td><a href="#FlashCookieManager.shutdown">shutdown</a></td> -<td>Public method to perform shutdown actions.</td> -</tr> -</table> -<h3>Static Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> - -<a NAME="FlashCookieManager.__init__" ID="FlashCookieManager.__init__"></a> -<h4>FlashCookieManager (Constructor)</h4> -<b>FlashCookieManager</b>(<i>parent=None</i>) - -<p> - Constructor -</p> -<dl> - -<dt><i>parent</i> (QObject)</dt> -<dd> -reference to the parent object -</dd> -</dl> -<a NAME="FlashCookieManager.__autoRefresh" ID="FlashCookieManager.__autoRefresh"></a> -<h4>FlashCookieManager.__autoRefresh</h4> -<b>__autoRefresh</b>(<i></i>) - -<p> - Private slot to refresh the list of cookies. -</p> -<a NAME="FlashCookieManager.__extractOriginFrom" ID="FlashCookieManager.__extractOriginFrom"></a> -<h4>FlashCookieManager.__extractOriginFrom</h4> -<b>__extractOriginFrom</b>(<i>path</i>) - -<p> - Private method to extract the cookie origin given its file name. -</p> -<dl> - -<dt><i>path</i> (str)</dt> -<dd> -file name of the cookie file -</dd> -</dl> -<dl> -<dt>Return:</dt> -<dd> -cookie origin -</dd> -</dl> -<dl> -<dt>Return Type:</dt> -<dd> -str -</dd> -</dl> -<a NAME="FlashCookieManager.__insertFlashCookie" ID="FlashCookieManager.__insertFlashCookie"></a> -<h4>FlashCookieManager.__insertFlashCookie</h4> -<b>__insertFlashCookie</b>(<i>path</i>) - -<p> - Private method to insert a Flash cookie into the cache. -</p> -<dl> - -<dt><i>path</i> (str)</dt> -<dd> -Flash cookies path -</dd> -</dl> -<a NAME="FlashCookieManager.__isBlacklisted" ID="FlashCookieManager.__isBlacklisted"></a> -<h4>FlashCookieManager.__isBlacklisted</h4> -<b>__isBlacklisted</b>(<i>cookie</i>) - -<p> - Private method to check for a blacklisted cookie. -</p> -<dl> - -<dt><i>cookie</i> (FlashCookie)</dt> -<dd> -Flash cookie to be tested -</dd> -</dl> -<dl> -<dt>Return:</dt> -<dd> -flag indicating a blacklisted cookie -</dd> -</dl> -<dl> -<dt>Return Type:</dt> -<dd> -bool -</dd> -</dl> -<a NAME="FlashCookieManager.__isWhitelisted" ID="FlashCookieManager.__isWhitelisted"></a> -<h4>FlashCookieManager.__isWhitelisted</h4> -<b>__isWhitelisted</b>(<i>cookie</i>) - -<p> - Private method to check for a whitelisted cookie. -</p> -<dl> - -<dt><i>cookie</i> (FlashCookie)</dt> -<dd> -Flash cookie to be tested -</dd> -</dl> -<dl> -<dt>Return:</dt> -<dd> -flag indicating a whitelisted cookie -</dd> -</dl> -<dl> -<dt>Return Type:</dt> -<dd> -bool -</dd> -</dl> -<a NAME="FlashCookieManager.__loadFlashCookies" ID="FlashCookieManager.__loadFlashCookies"></a> -<h4>FlashCookieManager.__loadFlashCookies</h4> -<b>__loadFlashCookies</b>(<i></i>) - -<p> - Private slot to load the Flash cookies to be cached. -</p> -<a NAME="FlashCookieManager.__loadFlashCookiesFromPath" ID="FlashCookieManager.__loadFlashCookiesFromPath"></a> -<h4>FlashCookieManager.__loadFlashCookiesFromPath</h4> -<b>__loadFlashCookiesFromPath</b>(<i>path</i>) - -<p> - Private slot to load the Flash cookies from a path. -</p> -<dl> - -<dt><i>path</i> (str)</dt> -<dd> -Flash cookies path -</dd> -</dl> -<a NAME="FlashCookieManager.__removeAllButWhitelisted" ID="FlashCookieManager.__removeAllButWhitelisted"></a> -<h4>FlashCookieManager.__removeAllButWhitelisted</h4> -<b>__removeAllButWhitelisted</b>(<i></i>) - -<p> - Private method to remove all non-whitelisted cookies. -</p> -<a NAME="FlashCookieManager.__sharedObjectDirName" ID="FlashCookieManager.__sharedObjectDirName"></a> -<h4>FlashCookieManager.__sharedObjectDirName</h4> -<b>__sharedObjectDirName</b>(<i></i>) - -<p> - Private slot to determine the path of the shared data objects. -</p> -<dl> -<dt>Return:</dt> -<dd> -path of the shared data objects -</dd> -</dl> -<dl> -<dt>Return Type:</dt> -<dd> -str -</dd> -</dl> -<a NAME="FlashCookieManager.__startStopTimer" ID="FlashCookieManager.__startStopTimer"></a> -<h4>FlashCookieManager.__startStopTimer</h4> -<b>__startStopTimer</b>(<i></i>) - -<p> - Private slot to start or stop the auto refresh timer. -</p> -<a NAME="FlashCookieManager.clearCache" ID="FlashCookieManager.clearCache"></a> -<h4>FlashCookieManager.clearCache</h4> -<b>clearCache</b>(<i></i>) - -<p> - Public method to clear the list of cached Flash cookies. -</p> -<a NAME="FlashCookieManager.clearNewOrigins" ID="FlashCookieManager.clearNewOrigins"></a> -<h4>FlashCookieManager.clearNewOrigins</h4> -<b>clearNewOrigins</b>(<i></i>) - -<p> - Public method to clear the list of newly detected Flash cookies. -</p> -<a NAME="FlashCookieManager.flashCookies" ID="FlashCookieManager.flashCookies"></a> -<h4>FlashCookieManager.flashCookies</h4> -<b>flashCookies</b>(<i></i>) - -<p> - Public method to get the list of cached Flash cookies. -</p> -<dl> -<dt>Return:</dt> -<dd> -list of Flash cookies -</dd> -</dl> -<dl> -<dt>Return Type:</dt> -<dd> -list of FlashCookie -</dd> -</dl> -<a NAME="FlashCookieManager.flashPlayerDataPath" ID="FlashCookieManager.flashPlayerDataPath"></a> -<h4>FlashCookieManager.flashPlayerDataPath</h4> -<b>flashPlayerDataPath</b>(<i></i>) - -<p> - Public method to get the Flash Player data path. -</p> -<dl> -<dt>Return:</dt> -<dd> -Flash Player data path -</dd> -</dl> -<dl> -<dt>Return Type:</dt> -<dd> -str -</dd> -</dl> -<a NAME="FlashCookieManager.newCookiesList" ID="FlashCookieManager.newCookiesList"></a> -<h4>FlashCookieManager.newCookiesList</h4> -<b>newCookiesList</b>(<i></i>) - -<p> - Public method to get the list of newly detected Flash cookies. -</p> -<dl> -<dt>Return:</dt> -<dd> -list of newly detected Flash cookies -</dd> -</dl> -<dl> -<dt>Return Type:</dt> -<dd> -list of str -</dd> -</dl> -<a NAME="FlashCookieManager.preferencesChanged" ID="FlashCookieManager.preferencesChanged"></a> -<h4>FlashCookieManager.preferencesChanged</h4> -<b>preferencesChanged</b>(<i></i>) - -<p> - Public slot to handle a change of preferences. -</p> -<a NAME="FlashCookieManager.removeAllCookies" ID="FlashCookieManager.removeAllCookies"></a> -<h4>FlashCookieManager.removeAllCookies</h4> -<b>removeAllCookies</b>(<i></i>) - -<p> - Public method to remove all flash cookies. -</p> -<a NAME="FlashCookieManager.removeCookie" ID="FlashCookieManager.removeCookie"></a> -<h4>FlashCookieManager.removeCookie</h4> -<b>removeCookie</b>(<i>cookie</i>) - -<p> - Public method to remove a cookie of the list of cached cookies. -</p> -<dl> - -<dt><i>cookie</i> (FlashCookie)</dt> -<dd> -Flash cookie to be removed -</dd> -</dl> -<a NAME="FlashCookieManager.setFlashCookies" ID="FlashCookieManager.setFlashCookies"></a> -<h4>FlashCookieManager.setFlashCookies</h4> -<b>setFlashCookies</b>(<i>cookies</i>) - -<p> - Public method to set the list of cached Flash cookies. -</p> -<dl> - -<dt><i>cookies</i> (list of FlashCookie)</dt> -<dd> -list of Flash cookies to store -</dd> -</dl> -<a NAME="FlashCookieManager.showFlashCookieManagerDialog" ID="FlashCookieManager.showFlashCookieManagerDialog"></a> -<h4>FlashCookieManager.showFlashCookieManagerDialog</h4> -<b>showFlashCookieManagerDialog</b>(<i></i>) - -<p> - Public method to show the Flash cookies management dialog. -</p> -<a NAME="FlashCookieManager.shutdown" ID="FlashCookieManager.shutdown"></a> -<h4>FlashCookieManager.shutdown</h4> -<b>shutdown</b>(<i></i>) - -<p> - Public method to perform shutdown actions. -</p> -<div align="right"><a href="#top">Up</a></div> -<hr /> -</body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.WebBrowser.FlashCookieManager.FlashCookieManagerDialog.html Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,371 +0,0 @@ -<!DOCTYPE html> -<html><head> -<title>eric6.WebBrowser.FlashCookieManager.FlashCookieManagerDialog</title> -<meta charset="UTF-8"> -<style> -body { - background: #EDECE6; - margin: 0em 1em 10em 1em; - color: black; -} - -h1 { color: white; background: #85774A; } -h2 { color: white; background: #85774A; } -h3 { color: white; background: #9D936E; } -h4 { color: white; background: #9D936E; } - -a { color: #BA6D36; } - -</style> -</head> -<body> -<a NAME="top" ID="top"></a> -<h1>eric6.WebBrowser.FlashCookieManager.FlashCookieManagerDialog</h1> - -<p> -Module implementing a dialog to manage the flash cookies. -</p> -<h3>Global Attributes</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Classes</h3> - -<table> - -<tr> -<td><a href="#FlashCookieManagerDialog">FlashCookieManagerDialog</a></td> -<td>Class implementing a dialog to manage the flash cookies.</td> -</tr> -</table> -<h3>Functions</h3> - -<table> -<tr><td>None</td></tr> -</table> -<hr /> -<hr /> -<a NAME="FlashCookieManagerDialog" ID="FlashCookieManagerDialog"></a> -<h2>FlashCookieManagerDialog</h2> - -<p> - Class implementing a dialog to manage the flash cookies. -</p> -<h3>Derived from</h3> -QDialog, Ui_FlashCookieManagerDialog -<h3>Class Attributes</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Class Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Methods</h3> - -<table> - -<tr> -<td><a href="#FlashCookieManagerDialog.__init__">FlashCookieManagerDialog</a></td> -<td>Constructor</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.__addBlacklist">__addBlacklist</a></td> -<td>Private method to add a cookie origin to the blacklist.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.__addWhitelist">__addWhitelist</a></td> -<td>Private method to add a cookie origin to the whitelist.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.__cookiesListContextMenuRequested">__cookiesListContextMenuRequested</a></td> -<td>Private slot handling the cookies list context menu.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.__refreshCookiesList">__refreshCookiesList</a></td> -<td>Private slot to refresh the cookies list.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.__refreshFilterLists">__refreshFilterLists</a></td> -<td>Private slot to refresh the white and black lists.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.closeEvent">closeEvent</a></td> -<td>Protected method to handle the close event.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.on_addBlackButton_clicked">on_addBlackButton_clicked</a></td> -<td>Private slot to add a server to the blacklist.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.on_addWhiteButton_clicked">on_addWhiteButton_clicked</a></td> -<td>Private slot to add a server to the whitelist.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.on_blackList_itemSelectionChanged">on_blackList_itemSelectionChanged</a></td> -<td>Private slot handling the selection of items in the blacklist.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.on_cookiesList_currentItemChanged">on_cookiesList_currentItemChanged</a></td> -<td>Private slot handling a change of the current cookie item.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.on_filterEdit_textChanged">on_filterEdit_textChanged</a></td> -<td>Private slot to filter the cookies list.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.on_reloadButton_clicked">on_reloadButton_clicked</a></td> -<td>Private slot handling a press of the reload button.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.on_removeAllButton_clicked">on_removeAllButton_clicked</a></td> -<td>Private slot to remove all cookies.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.on_removeBlackButton_clicked">on_removeBlackButton_clicked</a></td> -<td>Private slot to remove a server from the blacklist.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.on_removeButton_clicked">on_removeButton_clicked</a></td> -<td>Private slot to remove one cookie or a cookie group.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.on_removeWhiteButton_clicked">on_removeWhiteButton_clicked</a></td> -<td>Private slot to remove a server from the whitelist.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.on_whiteList_itemSelectionChanged">on_whiteList_itemSelectionChanged</a></td> -<td>Private slot handling the selection of items in the whitelist.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.refreshView">refreshView</a></td> -<td>Public method to refresh the dialog view.</td> -</tr> -<tr> -<td><a href="#FlashCookieManagerDialog.showPage">showPage</a></td> -<td>Public method to display a given page.</td> -</tr> -</table> -<h3>Static Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> - -<a NAME="FlashCookieManagerDialog.__init__" ID="FlashCookieManagerDialog.__init__"></a> -<h4>FlashCookieManagerDialog (Constructor)</h4> -<b>FlashCookieManagerDialog</b>(<i>manager, parent=None</i>) - -<p> - Constructor -</p> -<dl> - -<dt><i>manager</i> (FlashCookieManager)</dt> -<dd> -reference to the Flash cookie manager object -</dd> -<dt><i>parent</i> (QWidget)</dt> -<dd> -reference to the parent widget -</dd> -</dl> -<a NAME="FlashCookieManagerDialog.__addBlacklist" ID="FlashCookieManagerDialog.__addBlacklist"></a> -<h4>FlashCookieManagerDialog.__addBlacklist</h4> -<b>__addBlacklist</b>(<i>origin</i>) - -<p> - Private method to add a cookie origin to the blacklist. -</p> -<dl> - -<dt><i>origin</i> (str)</dt> -<dd> -origin to be added to the list -</dd> -</dl> -<a NAME="FlashCookieManagerDialog.__addWhitelist" ID="FlashCookieManagerDialog.__addWhitelist"></a> -<h4>FlashCookieManagerDialog.__addWhitelist</h4> -<b>__addWhitelist</b>(<i>origin</i>) - -<p> - Private method to add a cookie origin to the whitelist. -</p> -<dl> - -<dt><i>origin</i> (str)</dt> -<dd> -origin to be added to the list -</dd> -</dl> -<a NAME="FlashCookieManagerDialog.__cookiesListContextMenuRequested" ID="FlashCookieManagerDialog.__cookiesListContextMenuRequested"></a> -<h4>FlashCookieManagerDialog.__cookiesListContextMenuRequested</h4> -<b>__cookiesListContextMenuRequested</b>(<i>pos</i>) - -<p> - Private slot handling the cookies list context menu. -</p> -<dl> - -<dt><i>pos</i> (QPoint)</dt> -<dd> -position to show the menu at -</dd> -</dl> -<a NAME="FlashCookieManagerDialog.__refreshCookiesList" ID="FlashCookieManagerDialog.__refreshCookiesList"></a> -<h4>FlashCookieManagerDialog.__refreshCookiesList</h4> -<b>__refreshCookiesList</b>(<i></i>) - -<p> - Private slot to refresh the cookies list. -</p> -<a NAME="FlashCookieManagerDialog.__refreshFilterLists" ID="FlashCookieManagerDialog.__refreshFilterLists"></a> -<h4>FlashCookieManagerDialog.__refreshFilterLists</h4> -<b>__refreshFilterLists</b>(<i></i>) - -<p> - Private slot to refresh the white and black lists. -</p> -<a NAME="FlashCookieManagerDialog.closeEvent" ID="FlashCookieManagerDialog.closeEvent"></a> -<h4>FlashCookieManagerDialog.closeEvent</h4> -<b>closeEvent</b>(<i>evt</i>) - -<p> - Protected method to handle the close event. -</p> -<dl> - -<dt><i>evt</i> (QCloseEvent)</dt> -<dd> -reference to the close event -</dd> -</dl> -<a NAME="FlashCookieManagerDialog.on_addBlackButton_clicked" ID="FlashCookieManagerDialog.on_addBlackButton_clicked"></a> -<h4>FlashCookieManagerDialog.on_addBlackButton_clicked</h4> -<b>on_addBlackButton_clicked</b>(<i></i>) - -<p> - Private slot to add a server to the blacklist. -</p> -<a NAME="FlashCookieManagerDialog.on_addWhiteButton_clicked" ID="FlashCookieManagerDialog.on_addWhiteButton_clicked"></a> -<h4>FlashCookieManagerDialog.on_addWhiteButton_clicked</h4> -<b>on_addWhiteButton_clicked</b>(<i></i>) - -<p> - Private slot to add a server to the whitelist. -</p> -<a NAME="FlashCookieManagerDialog.on_blackList_itemSelectionChanged" ID="FlashCookieManagerDialog.on_blackList_itemSelectionChanged"></a> -<h4>FlashCookieManagerDialog.on_blackList_itemSelectionChanged</h4> -<b>on_blackList_itemSelectionChanged</b>(<i></i>) - -<p> - Private slot handling the selection of items in the blacklist. -</p> -<a NAME="FlashCookieManagerDialog.on_cookiesList_currentItemChanged" ID="FlashCookieManagerDialog.on_cookiesList_currentItemChanged"></a> -<h4>FlashCookieManagerDialog.on_cookiesList_currentItemChanged</h4> -<b>on_cookiesList_currentItemChanged</b>(<i>current, previous</i>) - -<p> - Private slot handling a change of the current cookie item. -</p> -<dl> - -<dt><i>current</i> (QTreeWidgetItem)</dt> -<dd> -reference to the current item -</dd> -<dt><i>previous</i> (QTreeWidgetItem)</dt> -<dd> -reference to the previous item -</dd> -</dl> -<a NAME="FlashCookieManagerDialog.on_filterEdit_textChanged" ID="FlashCookieManagerDialog.on_filterEdit_textChanged"></a> -<h4>FlashCookieManagerDialog.on_filterEdit_textChanged</h4> -<b>on_filterEdit_textChanged</b>(<i>filterStr</i>) - -<p> - Private slot to filter the cookies list. -</p> -<dl> - -<dt><i>filterStr</i> (str)</dt> -<dd> -filter text -</dd> -</dl> -<a NAME="FlashCookieManagerDialog.on_reloadButton_clicked" ID="FlashCookieManagerDialog.on_reloadButton_clicked"></a> -<h4>FlashCookieManagerDialog.on_reloadButton_clicked</h4> -<b>on_reloadButton_clicked</b>(<i></i>) - -<p> - Private slot handling a press of the reload button. -</p> -<a NAME="FlashCookieManagerDialog.on_removeAllButton_clicked" ID="FlashCookieManagerDialog.on_removeAllButton_clicked"></a> -<h4>FlashCookieManagerDialog.on_removeAllButton_clicked</h4> -<b>on_removeAllButton_clicked</b>(<i></i>) - -<p> - Private slot to remove all cookies. -</p> -<a NAME="FlashCookieManagerDialog.on_removeBlackButton_clicked" ID="FlashCookieManagerDialog.on_removeBlackButton_clicked"></a> -<h4>FlashCookieManagerDialog.on_removeBlackButton_clicked</h4> -<b>on_removeBlackButton_clicked</b>(<i></i>) - -<p> - Private slot to remove a server from the blacklist. -</p> -<a NAME="FlashCookieManagerDialog.on_removeButton_clicked" ID="FlashCookieManagerDialog.on_removeButton_clicked"></a> -<h4>FlashCookieManagerDialog.on_removeButton_clicked</h4> -<b>on_removeButton_clicked</b>(<i></i>) - -<p> - Private slot to remove one cookie or a cookie group. -</p> -<a NAME="FlashCookieManagerDialog.on_removeWhiteButton_clicked" ID="FlashCookieManagerDialog.on_removeWhiteButton_clicked"></a> -<h4>FlashCookieManagerDialog.on_removeWhiteButton_clicked</h4> -<b>on_removeWhiteButton_clicked</b>(<i></i>) - -<p> - Private slot to remove a server from the whitelist. -</p> -<a NAME="FlashCookieManagerDialog.on_whiteList_itemSelectionChanged" ID="FlashCookieManagerDialog.on_whiteList_itemSelectionChanged"></a> -<h4>FlashCookieManagerDialog.on_whiteList_itemSelectionChanged</h4> -<b>on_whiteList_itemSelectionChanged</b>(<i></i>) - -<p> - Private slot handling the selection of items in the whitelist. -</p> -<a NAME="FlashCookieManagerDialog.refreshView" ID="FlashCookieManagerDialog.refreshView"></a> -<h4>FlashCookieManagerDialog.refreshView</h4> -<b>refreshView</b>(<i>forceReload=False</i>) - -<p> - Public method to refresh the dialog view. -</p> -<dl> - -<dt><i>forceReload</i> (bool)</dt> -<dd> -flag indicating to reload the cookies -</dd> -</dl> -<a NAME="FlashCookieManagerDialog.showPage" ID="FlashCookieManagerDialog.showPage"></a> -<h4>FlashCookieManagerDialog.showPage</h4> -<b>showPage</b>(<i>index</i>) - -<p> - Public method to display a given page. -</p> -<dl> - -<dt><i>index</i> (int)</dt> -<dd> -index of the page to be shown -</dd> -</dl> -<div align="right"><a href="#top">Up</a></div> -<hr /> -</body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.WebBrowser.FlashCookieManager.FlashCookieNotification.html Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,106 +0,0 @@ -<!DOCTYPE html> -<html><head> -<title>eric6.WebBrowser.FlashCookieManager.FlashCookieNotification</title> -<meta charset="UTF-8"> -<style> -body { - background: #EDECE6; - margin: 0em 1em 10em 1em; - color: black; -} - -h1 { color: white; background: #85774A; } -h2 { color: white; background: #85774A; } -h3 { color: white; background: #9D936E; } -h4 { color: white; background: #9D936E; } - -a { color: #BA6D36; } - -</style> -</head> -<body> -<a NAME="top" ID="top"></a> -<h1>eric6.WebBrowser.FlashCookieManager.FlashCookieNotification</h1> - -<p> -Module implementing the feature permission bar widget. -</p> -<h3>Global Attributes</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Classes</h3> - -<table> - -<tr> -<td><a href="#FlashCookieNotification">FlashCookieNotification</a></td> -<td>Class implementing the feature permission bar widget.</td> -</tr> -</table> -<h3>Functions</h3> - -<table> -<tr><td>None</td></tr> -</table> -<hr /> -<hr /> -<a NAME="FlashCookieNotification" ID="FlashCookieNotification"></a> -<h2>FlashCookieNotification</h2> - -<p> - Class implementing the feature permission bar widget. -</p> -<h3>Derived from</h3> -E5AnimatedWidget -<h3>Class Attributes</h3> - -<table> -<tr><td>DefaultHeight</td></tr> -</table> -<h3>Class Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Methods</h3> - -<table> - -<tr> -<td><a href="#FlashCookieNotification.__init__">FlashCookieNotification</a></td> -<td>Constructor</td> -</tr> -</table> -<h3>Static Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> - -<a NAME="FlashCookieNotification.__init__" ID="FlashCookieNotification.__init__"></a> -<h4>FlashCookieNotification (Constructor)</h4> -<b>FlashCookieNotification</b>(<i>view, manager, noCookies</i>) - -<p> - Constructor -</p> -<dl> - -<dt><i>view</i> (WebBrowserView)</dt> -<dd> -reference to the web view -</dd> -<dt><i>manager</i> (FlashCookieManager)</dt> -<dd> -reference to the Flash cookie manager object -</dd> -<dt><i>noCookies</i> (int)</dt> -<dd> -number of newly detected Flash cookies -</dd> -</dl> -<div align="right"><a href="#top">Up</a></div> -<hr /> -</body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.WebBrowser.FlashCookieManager.FlashCookieReader.html Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,518 +0,0 @@ -<!DOCTYPE html> -<html><head> -<title>eric6.WebBrowser.FlashCookieManager.FlashCookieReader</title> -<meta charset="UTF-8"> -<style> -body { - background: #EDECE6; - margin: 0em 1em 10em 1em; - color: black; -} - -h1 { color: white; background: #85774A; } -h2 { color: white; background: #85774A; } -h3 { color: white; background: #9D936E; } -h4 { color: white; background: #9D936E; } - -a { color: #BA6D36; } - -</style> -</head> -<body> -<a NAME="top" ID="top"></a> -<h1>eric6.WebBrowser.FlashCookieManager.FlashCookieReader</h1> - -<p> -Module implementing a class to read flash cookies. -</p> -<h3>Global Attributes</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Classes</h3> - -<table> - -<tr> -<td><a href="#FlashCookieReader">FlashCookieReader</a></td> -<td>Class implementing a reader for flash cookies (*.sol files).</td> -</tr> -<tr> -<td><a href="#FlashCookieReaderError">FlashCookieReaderError</a></td> -<td>Class containing data of a reader error.</td> -</tr> -</table> -<h3>Functions</h3> - -<table> -<tr><td>None</td></tr> -</table> -<hr /> -<hr /> -<a NAME="FlashCookieReader" ID="FlashCookieReader"></a> -<h2>FlashCookieReader</h2> - -<p> - Class implementing a reader for flash cookies (*.sol files). -</p> -<h3>Derived from</h3> -object -<h3>Class Attributes</h3> - -<table> -<tr><td>Boolean</td></tr><tr><td>EpochCorrectionMsecs</td></tr><tr><td>Null</td></tr><tr><td>Number</td></tr><tr><td>ObjArr</td></tr><tr><td>ObjCc</td></tr><tr><td>ObjDate</td></tr><tr><td>ObjM</td></tr><tr><td>ObjObj</td></tr><tr><td>ObjXml</td></tr><tr><td>String</td></tr><tr><td>Undef</td></tr> -</table> -<h3>Class Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Methods</h3> - -<table> - -<tr> -<td><a href="#FlashCookieReader.__init__">FlashCookieReader</a></td> -<td>Constructor</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.__parseArray">__parseArray</a></td> -<td>Private method to parse an array.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.__parseBoolean">__parseBoolean</a></td> -<td>Private method to parse a boolean.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.__parseDate">__parseDate</a></td> -<td>Private method to parse a date.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.__parseNull">__parseNull</a></td> -<td>Private method to parse a null object.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.__parseNumber">__parseNumber</a></td> -<td>Private method to parse a number.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.__parseObject">__parseObject</a></td> -<td>Private method to parse an object.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.__parseOcc">__parseOcc</a></td> -<td>Private method to parse a c_object.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.__parseOjm">__parseOjm</a></td> -<td>Private method to parse an m_object.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.__parseString">__parseString</a></td> -<td>Private method to parse a string.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.__parseUndefined">__parseUndefined</a></td> -<td>Private method to parse an undefined object.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.__parseXml">__parseXml</a></td> -<td>Private method to parse XML.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.parse">parse</a></td> -<td>Public method to parse the sol file.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.setBytes">setBytes</a></td> -<td>Public method to set the contents of a sol file to be parsed.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.setFile">setFile</a></td> -<td>Public method to set an open sol file to be parsed.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.setFileName">setFileName</a></td> -<td>Public method to set the name of a sol file to be parsed.</td> -</tr> -<tr> -<td><a href="#FlashCookieReader.toString">toString</a></td> -<td>Public method to convert the parsed cookie to a string representation.</td> -</tr> -</table> -<h3>Static Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> - -<a NAME="FlashCookieReader.__init__" ID="FlashCookieReader.__init__"></a> -<h4>FlashCookieReader (Constructor)</h4> -<b>FlashCookieReader</b>(<i></i>) - -<p> - Constructor -</p> -<a NAME="FlashCookieReader.__parseArray" ID="FlashCookieReader.__parseArray"></a> -<h4>FlashCookieReader.__parseArray</h4> -<b>__parseArray</b>(<i>variableName, parent</i>) - -<p> - Private method to parse an array. -</p> -<dl> - -<dt><i>variableName</i> (str)</dt> -<dd> -name of the variable to be parsed -</dd> -<dt><i>parent</i> (dict)</dt> -<dd> -reference to the dictionary to insert the result into -</dd> -</dl> -<dl> - -<dt>Raises <b>FlashCookieReaderError</b>:</dt> -<dd> -raised when an issue with the cookie - file is found -</dd> -</dl> -<a NAME="FlashCookieReader.__parseBoolean" ID="FlashCookieReader.__parseBoolean"></a> -<h4>FlashCookieReader.__parseBoolean</h4> -<b>__parseBoolean</b>(<i>variableName, parent</i>) - -<p> - Private method to parse a boolean. -</p> -<dl> - -<dt><i>variableName</i> (str)</dt> -<dd> -name of the variable to be parsed -</dd> -<dt><i>parent</i> (dict)</dt> -<dd> -reference to the dictionary to insert the result into -</dd> -</dl> -<a NAME="FlashCookieReader.__parseDate" ID="FlashCookieReader.__parseDate"></a> -<h4>FlashCookieReader.__parseDate</h4> -<b>__parseDate</b>(<i>variableName, parent</i>) - -<p> - Private method to parse a date. -</p> -<dl> - -<dt><i>variableName</i> (str)</dt> -<dd> -name of the variable to be parsed -</dd> -<dt><i>parent</i> (dict)</dt> -<dd> -reference to the dictionary to insert the result into -</dd> -</dl> -<a NAME="FlashCookieReader.__parseNull" ID="FlashCookieReader.__parseNull"></a> -<h4>FlashCookieReader.__parseNull</h4> -<b>__parseNull</b>(<i>variableName, parent</i>) - -<p> - Private method to parse a null object. -</p> -<dl> - -<dt><i>variableName</i> (str)</dt> -<dd> -name of the variable to be parsed -</dd> -<dt><i>parent</i> (dict)</dt> -<dd> -reference to the dictionary to insert the result into -</dd> -</dl> -<a NAME="FlashCookieReader.__parseNumber" ID="FlashCookieReader.__parseNumber"></a> -<h4>FlashCookieReader.__parseNumber</h4> -<b>__parseNumber</b>(<i>variableName, parent</i>) - -<p> - Private method to parse a number. -</p> -<dl> - -<dt><i>variableName</i> (str)</dt> -<dd> -name of the variable to be parsed -</dd> -<dt><i>parent</i> (dict)</dt> -<dd> -reference to the dictionary to insert the result into -</dd> -</dl> -<a NAME="FlashCookieReader.__parseObject" ID="FlashCookieReader.__parseObject"></a> -<h4>FlashCookieReader.__parseObject</h4> -<b>__parseObject</b>(<i>variableName, parent</i>) - -<p> - Private method to parse an object. -</p> -<dl> - -<dt><i>variableName</i> (str)</dt> -<dd> -name of the variable to be parsed -</dd> -<dt><i>parent</i> (dict)</dt> -<dd> -reference to the dictionary to insert the result into -</dd> -</dl> -<dl> - -<dt>Raises <b>FlashCookieReaderError</b>:</dt> -<dd> -raised when an issue with the cookie - file is found -</dd> -</dl> -<a NAME="FlashCookieReader.__parseOcc" ID="FlashCookieReader.__parseOcc"></a> -<h4>FlashCookieReader.__parseOcc</h4> -<b>__parseOcc</b>(<i>variableName, parent</i>) - -<p> - Private method to parse a c_object. -</p> -<dl> - -<dt><i>variableName</i> (str)</dt> -<dd> -name of the variable to be parsed -</dd> -<dt><i>parent</i> (dict)</dt> -<dd> -reference to the dictionary to insert the result into -</dd> -</dl> -<dl> - -<dt>Raises <b>FlashCookieReaderError</b>:</dt> -<dd> -raised when an issue with the cookie - file is found -</dd> -</dl> -<a NAME="FlashCookieReader.__parseOjm" ID="FlashCookieReader.__parseOjm"></a> -<h4>FlashCookieReader.__parseOjm</h4> -<b>__parseOjm</b>(<i>variableName, parent</i>) - -<p> - Private method to parse an m_object. -</p> -<dl> - -<dt><i>variableName</i> (str)</dt> -<dd> -name of the variable to be parsed -</dd> -<dt><i>parent</i> (dict)</dt> -<dd> -reference to the dictionary to insert the result into -</dd> -</dl> -<a NAME="FlashCookieReader.__parseString" ID="FlashCookieReader.__parseString"></a> -<h4>FlashCookieReader.__parseString</h4> -<b>__parseString</b>(<i>variableName, parent</i>) - -<p> - Private method to parse a string. -</p> -<dl> - -<dt><i>variableName</i> (str)</dt> -<dd> -name of the variable to be parsed -</dd> -<dt><i>parent</i> (dict)</dt> -<dd> -reference to the dictionary to insert the result into -</dd> -</dl> -<a NAME="FlashCookieReader.__parseUndefined" ID="FlashCookieReader.__parseUndefined"></a> -<h4>FlashCookieReader.__parseUndefined</h4> -<b>__parseUndefined</b>(<i>variableName, parent</i>) - -<p> - Private method to parse an undefined object. -</p> -<dl> - -<dt><i>variableName</i> (str)</dt> -<dd> -name of the variable to be parsed -</dd> -<dt><i>parent</i> (dict)</dt> -<dd> -reference to the dictionary to insert the result into -</dd> -</dl> -<a NAME="FlashCookieReader.__parseXml" ID="FlashCookieReader.__parseXml"></a> -<h4>FlashCookieReader.__parseXml</h4> -<b>__parseXml</b>(<i>variableName, parent</i>) - -<p> - Private method to parse XML. -</p> -<dl> - -<dt><i>variableName</i> (str)</dt> -<dd> -name of the variable to be parsed -</dd> -<dt><i>parent</i> (dict)</dt> -<dd> -reference to the dictionary to insert the result into -</dd> -</dl> -<a NAME="FlashCookieReader.parse" ID="FlashCookieReader.parse"></a> -<h4>FlashCookieReader.parse</h4> -<b>parse</b>(<i></i>) - -<p> - Public method to parse the sol file. -</p> -<dl> - -<dt>Raises <b>FlashCookieReaderError</b>:</dt> -<dd> -raised when encountering a parse - issue -</dd> -</dl> -<a NAME="FlashCookieReader.setBytes" ID="FlashCookieReader.setBytes"></a> -<h4>FlashCookieReader.setBytes</h4> -<b>setBytes</b>(<i>solData</i>) - -<p> - Public method to set the contents of a sol file to be parsed. -</p> -<dl> - -<dt><i>solData</i> (bytes)</dt> -<dd> -contents of the file -</dd> -</dl> -<a NAME="FlashCookieReader.setFile" ID="FlashCookieReader.setFile"></a> -<h4>FlashCookieReader.setFile</h4> -<b>setFile</b>(<i>solFile</i>) - -<p> - Public method to set an open sol file to be parsed. -</p> -<dl> - -<dt><i>solFile</i> (io.FileIO)</dt> -<dd> -sol file to be parsed -</dd> -</dl> -<a NAME="FlashCookieReader.setFileName" ID="FlashCookieReader.setFileName"></a> -<h4>FlashCookieReader.setFileName</h4> -<b>setFileName</b>(<i>solFilename</i>) - -<p> - Public method to set the name of a sol file to be parsed. -</p> -<dl> - -<dt><i>solFilename</i> (str)</dt> -<dd> -name of the sol file -</dd> -</dl> -<a NAME="FlashCookieReader.toString" ID="FlashCookieReader.toString"></a> -<h4>FlashCookieReader.toString</h4> -<b>toString</b>(<i>indent=0, parent=None</i>) - -<p> - Public method to convert the parsed cookie to a string representation. -</p> -<dl> - -<dt><i>indent</i> (int)</dt> -<dd> -indentation level -</dd> -<dt><i>parent</i> (dict)</dt> -<dd> -reference to the dictionary to be converted -</dd> -</dl> -<dl> -<dt>Return:</dt> -<dd> -string representation of the cookie -</dd> -</dl> -<dl> -<dt>Return Type:</dt> -<dd> -str -</dd> -</dl> -<div align="right"><a href="#top">Up</a></div> -<hr /> -<hr /> -<a NAME="FlashCookieReaderError" ID="FlashCookieReaderError"></a> -<h2>FlashCookieReaderError</h2> - -<p> - Class containing data of a reader error. -</p> -<h3>Derived from</h3> -Exception -<h3>Class Attributes</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Class Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Methods</h3> - -<table> - -<tr> -<td><a href="#FlashCookieReaderError.__init__">FlashCookieReaderError</a></td> -<td>Constructor</td> -</tr> -</table> -<h3>Static Methods</h3> - -<table> -<tr><td>None</td></tr> -</table> - -<a NAME="FlashCookieReaderError.__init__" ID="FlashCookieReaderError.__init__"></a> -<h4>FlashCookieReaderError (Constructor)</h4> -<b>FlashCookieReaderError</b>(<i>msg</i>) - -<p> - Constructor -</p> -<dl> - -<dt><i>msg</i> (str)</dt> -<dd> -error message -</dd> -</dl> -<div align="right"><a href="#top">Up</a></div> -<hr /> -</body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/eric6.WebBrowser.FlashCookieManager.FlashCookieUtilities.html Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,71 +0,0 @@ -<!DOCTYPE html> -<html><head> -<title>eric6.WebBrowser.FlashCookieManager.FlashCookieUtilities</title> -<meta charset="UTF-8"> -<style> -body { - background: #EDECE6; - margin: 0em 1em 10em 1em; - color: black; -} - -h1 { color: white; background: #85774A; } -h2 { color: white; background: #85774A; } -h3 { color: white; background: #9D936E; } -h4 { color: white; background: #9D936E; } - -a { color: #BA6D36; } - -</style> -</head> -<body> -<a NAME="top" ID="top"></a> -<h1>eric6.WebBrowser.FlashCookieManager.FlashCookieUtilities</h1> - -<p> -Module implementing some utility functions. -</p> -<h3>Global Attributes</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Classes</h3> - -<table> -<tr><td>None</td></tr> -</table> -<h3>Functions</h3> - -<table> - -<tr> -<td><a href="#flashDataPathForOS">flashDataPathForOS</a></td> -<td>Function to determine the OS dependent path where Flash cookies are stored.</td> -</tr> -</table> -<hr /> -<hr /> -<a NAME="flashDataPathForOS" ID="flashDataPathForOS"></a> -<h2>flashDataPathForOS</h2> -<b>flashDataPathForOS</b>(<i></i>) - -<p> - Function to determine the OS dependent path where Flash cookies - are stored. -</p> -<dl> -<dt>Return:</dt> -<dd> -Flash data path -</dd> -</dl> -<dl> -<dt>Return Type:</dt> -<dd> -str -</dd> -</dl> -<div align="right"><a href="#top">Up</a></div> -<hr /> -</body></html> \ No newline at end of file
--- a/eric6/Documentation/Source/index-eric6.WebBrowser.FlashCookieManager.html Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,57 +0,0 @@ -<!DOCTYPE html> -<html><head> -<title>eric6.WebBrowser.FlashCookieManager</title> -<meta charset="UTF-8"> -<style> -body { - background: #EDECE6; - margin: 0em 1em 10em 1em; - color: black; -} - -h1 { color: white; background: #85774A; } -h2 { color: white; background: #85774A; } -h3 { color: white; background: #9D936E; } -h4 { color: white; background: #9D936E; } - -a { color: #BA6D36; } - -</style> -</head> -<body> -<h1>eric6.WebBrowser.FlashCookieManager</h1> - -<p> -Package implementing the Flash cookie manager and associated objects. -</p> - - -<h3>Modules</h3> -<table> - -<tr> -<td><a href="eric6.WebBrowser.FlashCookieManager.FlashCookie.html">FlashCookie</a></td> -<td>Module implementing the Flash cookie class.</td> -</tr> -<tr> -<td><a href="eric6.WebBrowser.FlashCookieManager.FlashCookieManager.html">FlashCookieManager</a></td> -<td>Module implementing the Flash cookie manager.</td> -</tr> -<tr> -<td><a href="eric6.WebBrowser.FlashCookieManager.FlashCookieManagerDialog.html">FlashCookieManagerDialog</a></td> -<td>Module implementing a dialog to manage the flash cookies.</td> -</tr> -<tr> -<td><a href="eric6.WebBrowser.FlashCookieManager.FlashCookieNotification.html">FlashCookieNotification</a></td> -<td>Module implementing the feature permission bar widget.</td> -</tr> -<tr> -<td><a href="eric6.WebBrowser.FlashCookieManager.FlashCookieReader.html">FlashCookieReader</a></td> -<td>Module implementing a class to read flash cookies.</td> -</tr> -<tr> -<td><a href="eric6.WebBrowser.FlashCookieManager.FlashCookieUtilities.html">FlashCookieUtilities</a></td> -<td>Module implementing some utility functions.</td> -</tr> -</table> -</body></html> \ No newline at end of file
--- a/eric6/Preferences/ConfigurationDialog.py Thu Feb 04 14:38:33 2021 +0100 +++ b/eric6/Preferences/ConfigurationDialog.py Thu Feb 04 14:59:13 2021 +0100 @@ -346,11 +346,6 @@ "webBrowserPage": [self.tr("eric Web Browser"), "ericWeb", "WebBrowserPage", "0webBrowserPage", None], - "webBrowserFlashCookieManagerPage": - [self.tr("Flash Cookie Manager"), - "flashCookie16", - "WebBrowserFlashCookieManagerPage", "0webBrowserPage", - None], "webBrowserVirusTotalPage": [self.tr("VirusTotal Interface"), "virustotal", "WebBrowserVirusTotalPage", "0webBrowserPage", None], @@ -397,10 +392,6 @@ [self.tr("eric Web Browser"), "ericWeb", "WebBrowserPage", None, None], - "webBrowserFlashCookieManagerPage": - [self.tr("Flash Cookie Manager"), - "flashCookie16", - "WebBrowserFlashCookieManagerPage", None, None], "webBrowserVirusTotalPage": [self.tr("VirusTotal Interface"), "virustotal", "WebBrowserVirusTotalPage", None, None],
--- a/eric6/Preferences/ConfigurationPages/WebBrowserFlashCookieManagerPage.py Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,67 +0,0 @@ -# -*- coding: utf-8 -*- - -# Copyright (c) 2015 - 2021 Detlev Offenbach <detlev@die-offenbachs.de> -# - -""" -Module implementing the Flash Cookies Manager configuration page. -""" - -from E5Gui.E5PathPicker import E5PathPickerModes - -from .ConfigurationPageBase import ConfigurationPageBase -from .Ui_WebBrowserFlashCookieManagerPage import ( - Ui_WebBrowserFlashCookieManagerPage -) - -import Preferences - - -class WebBrowserFlashCookieManagerPage(ConfigurationPageBase, - Ui_WebBrowserFlashCookieManagerPage): - """ - Class implementing the Flash Cookies Manager configuration page. - """ - def __init__(self): - """ - Constructor - """ - super(WebBrowserFlashCookieManagerPage, self).__init__() - self.setupUi(self) - self.setObjectName("WebBrowserFlashCookieManagerPage") - - self.flashDataPathPicker.setMode(E5PathPickerModes.DirectoryMode) - - # set initial values - self.flashDataPathPicker.setText( - Preferences.getWebBrowser("FlashCookiesDataPath")) - self.autoModeGroup.setChecked( - Preferences.getWebBrowser("FlashCookieAutoRefresh")) - self.notificationGroup.setChecked( - Preferences.getWebBrowser("FlashCookieNotify")) - self.deleteGroup.setChecked( - Preferences.getWebBrowser("FlashCookiesDeleteOnStartExit")) - - def save(self): - """ - Public slot to save the Flash Cookies Manager configuration. - """ - Preferences.setWebBrowser( - "FlashCookiesDataPath", self.flashDataPathPicker.text()) - Preferences.setWebBrowser( - "FlashCookieAutoRefresh", self.autoModeGroup.isChecked()) - Preferences.setWebBrowser( - "FlashCookieNotify", self.notificationGroup.isChecked()) - Preferences.setWebBrowser( - "FlashCookiesDeleteOnStartExit", self.deleteGroup.isChecked()) - - -def create(dlg): - """ - Module function to create the configuration page. - - @param dlg reference to the configuration dialog - @return reference to the instantiated page (ConfigurationPageBase) - """ - page = WebBrowserFlashCookieManagerPage() - return page
--- a/eric6/Preferences/ConfigurationPages/WebBrowserFlashCookieManagerPage.ui Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,200 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<ui version="4.0"> - <class>WebBrowserFlashCookieManagerPage</class> - <widget class="QWidget" name="WebBrowserFlashCookieManagerPage"> - <property name="geometry"> - <rect> - <x>0</x> - <y>0</y> - <width>462</width> - <height>426</height> - </rect> - </property> - <layout class="QVBoxLayout" name="verticalLayout"> - <item> - <widget class="QLabel" name="headerLabel"> - <property name="text"> - <string><b>Configure Flash Cookies Manager</b></string> - </property> - </widget> - </item> - <item> - <widget class="Line" name="line9"> - <property name="frameShape"> - <enum>QFrame::HLine</enum> - </property> - <property name="frameShadow"> - <enum>QFrame::Sunken</enum> - </property> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - </widget> - </item> - <item> - <widget class="QGroupBox" name="groupBox"> - <property name="title"> - <string>Flash Data Path</string> - </property> - <layout class="QVBoxLayout" name="verticalLayout_2"> - <item> - <widget class="E5PathPicker" name="flashDataPathPicker" native="true"> - <property name="focusPolicy"> - <enum>Qt::StrongFocus</enum> - </property> - </widget> - </item> - <item> - <widget class="QLabel" name="label"> - <property name="text"> - <string><b>Note</b>: You should select the directory that contains #SharedObject as a subfolder.</string> - </property> - <property name="wordWrap"> - <bool>true</bool> - </property> - </widget> - </item> - </layout> - </widget> - </item> - <item> - <widget class="QGroupBox" name="autoModeGroup"> - <property name="toolTip"> - <string>Select to activate auto mode</string> - </property> - <property name="title"> - <string>Auto Mode Enabled</string> - </property> - <property name="checkable"> - <bool>true</bool> - </property> - <property name="checked"> - <bool>false</bool> - </property> - <layout class="QHBoxLayout" name="horizontalLayout"> - <item> - <widget class="QLabel" name="autoModeLabel"> - <property name="sizePolicy"> - <sizepolicy hsizetype="Expanding" vsizetype="Preferred"> - <horstretch>0</horstretch> - <verstretch>0</verstretch> - </sizepolicy> - </property> - <property name="text"> - <string>The flash data directory will be checked regularly and flash cookies in the blacklist will be deleted automatically.</string> - </property> - <property name="wordWrap"> - <bool>true</bool> - </property> - </widget> - </item> - </layout> - </widget> - </item> - <item> - <widget class="QGroupBox" name="notificationGroup"> - <property name="toolTip"> - <string>Select to show a notification upon detection of new flash cookies</string> - </property> - <property name="title"> - <string>Notifications enabled</string> - </property> - <property name="flat"> - <bool>false</bool> - </property> - <property name="checkable"> - <bool>true</bool> - </property> - <property name="checked"> - <bool>false</bool> - </property> - <layout class="QHBoxLayout" name="horizontalLayout_2"> - <item> - <widget class="QLabel" name="notificationLabel"> - <property name="sizePolicy"> - <sizepolicy hsizetype="Expanding" vsizetype="Preferred"> - <horstretch>0</horstretch> - <verstretch>0</verstretch> - </sizepolicy> - </property> - <property name="text"> - <string>User will be notified for every new flash cookie that is not in blacklist and whitelist.</string> - </property> - <property name="wordWrap"> - <bool>true</bool> - </property> - </widget> - </item> - </layout> - </widget> - </item> - <item> - <widget class="QGroupBox" name="deleteGroup"> - <property name="toolTip"> - <string>Select to delete all flash cookies on startup and shutdown</string> - </property> - <property name="title"> - <string>Delete</string> - </property> - <property name="checkable"> - <bool>true</bool> - </property> - <property name="checked"> - <bool>false</bool> - </property> - <layout class="QHBoxLayout" name="horizontalLayout_3"> - <item> - <widget class="QLabel" name="deleteLabel"> - <property name="text"> - <string>Delete all flash cookies on exit/start (except those are in whitelist)</string> - </property> - <property name="wordWrap"> - <bool>true</bool> - </property> - </widget> - </item> - </layout> - </widget> - </item> - <item> - <widget class="QLabel" name="label_19"> - <property name="text"> - <string><p><b>Note:</b> These settings are just applied to flash cookies.</p></string> - </property> - <property name="wordWrap"> - <bool>true</bool> - </property> - </widget> - </item> - <item> - <spacer name="verticalSpacer"> - <property name="orientation"> - <enum>Qt::Vertical</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>20</width> - <height>39</height> - </size> - </property> - </spacer> - </item> - </layout> - </widget> - <customwidgets> - <customwidget> - <class>E5PathPicker</class> - <extends>QWidget</extends> - <header>E5Gui/E5PathPicker.h</header> - <container>1</container> - </customwidget> - </customwidgets> - <tabstops> - <tabstop>flashDataPathPicker</tabstop> - <tabstop>autoModeGroup</tabstop> - <tabstop>notificationGroup</tabstop> - <tabstop>deleteGroup</tabstop> - </tabstops> - <resources/> - <connections/> -</ui>
--- a/eric6/Preferences/__init__.py Thu Feb 04 14:38:33 2021 +0100 +++ b/eric6/Preferences/__init__.py Thu Feb 04 14:59:13 2021 +0100 @@ -47,10 +47,6 @@ ProtocolsBrowserFlag, AllBrowsersFlag ) -from WebBrowser.FlashCookieManager.FlashCookieUtilities import ( - flashDataPathForOS -) - from QScintilla.Shell import ShellHistoryStyle @@ -1012,13 +1008,6 @@ "AdBlockUpdatePeriod": 1, "AdBlockExceptions": [], "AdBlockUseLimitedEasyList": True, - # Flash Cookie Manager - "FlashCookiesDeleteOnStartExit": False, - "FlashCookieAutoRefresh": False, - "FlashCookieNotify": False, - "FlashCookiesWhitelist": [], - "FlashCookiesBlacklist": [], - "FlashCookiesDataPath": flashDataPathForOS(), # PIM: "PimFullName": "", "PimFirstName": "", @@ -2842,15 +2831,13 @@ "DownloadManagerAutoOpen", "DownloadManagerAutoClose", "PlaybackRequiresUserGesture", "JavaScriptCanPaste", "WebRTCPublicInterfacesOnly", "DnsPrefetchEnabled", - "FlashCookiesDeleteOnStartExit", "FlashCookieAutoRefresh", - "FlashCookieNotify", "VirusTotalEnabled", "VirusTotalSecure", + "VirusTotalEnabled", "VirusTotalSecure", "PdfViewerEnabled", "AlwaysRejectFaultyCertificates", ]: return toBool(prefClass.settings.value( "WebBrowser/" + key, prefClass.webBrowserDefaults[key])) elif key in ["GreaseMonkeyDisabledScripts", "SendRefererWhitelist", "AdBlockSubscriptions", "AdBlockExceptions", - "FlashCookiesWhitelist", "FlashCookiesBlacklist", "SpellCheckLanguages", ]: return toList(prefClass.settings.value(
--- a/eric6/WebBrowser/FlashCookieManager/FlashCookie.py Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,38 +0,0 @@ -# -*- coding: utf-8 -*- - -# Copyright (c) 2015 - 2021 Detlev Offenbach <detlev@die-offenbachs.de> -# - -""" -Module implementing the Flash cookie class. -""" - -from PyQt5.QtCore import QDateTime - - -class FlashCookie(object): - """ - Class implementing the Flash cookie. - """ - def __init__(self): - """ - Constructor - """ - self.name = "" - self.origin = "" - self.size = 0 - self.path = "" - self.contents = "" - self.lastModified = QDateTime() - - def __eq__(self, other): - """ - Special method to compare to another Flash cookie. - - @param other reference to the other Flash cookie - @type FlashCookie - @return flag indicating equality of the two cookies - @rtype bool - """ - return (self.name == other.name and - self.path == other.path)
--- a/eric6/WebBrowser/FlashCookieManager/FlashCookieManager.py Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,362 +0,0 @@ -# -*- coding: utf-8 -*- - -# Copyright (c) 2015 - 2021 Detlev Offenbach <detlev@die-offenbachs.de> -# - -""" -Module implementing the Flash cookie manager. -""" - -import shutil - -from PyQt5.QtCore import QObject, QTimer, QDir, QFileInfo, QFile - -from .FlashCookie import FlashCookie -from .FlashCookieReader import FlashCookieReader, FlashCookieReaderError - -import WebBrowser.WebBrowserWindow - -import Preferences - - -class FlashCookieManager(QObject): - """ - Class implementing the Flash cookie manager object. - """ - RefreshInterval = 60 * 1000 - - def __init__(self, parent=None): - """ - Constructor - - @param parent reference to the parent object - @type QObject - """ - super(FlashCookieManager, self).__init__(parent) - - self.__flashCookieManagerDialog = None - self.__flashCookies = [] # list of FlashCookie - self.__newCookiesList = [] # list of str - - self.__timer = QTimer(self) - self.__timer.setInterval(FlashCookieManager.RefreshInterval) - self.__timer.timeout.connect(self.__autoRefresh) - - # start the timer if needed - self.__startStopTimer() - - if Preferences.getWebBrowser("FlashCookiesDeleteOnStartExit"): - self.__loadFlashCookies() - self.__removeAllButWhitelisted() - - def shutdown(self): - """ - Public method to perform shutdown actions. - """ - if self.__flashCookieManagerDialog is not None: - self.__flashCookieManagerDialog.close() - - if Preferences.getWebBrowser("FlashCookiesDeleteOnStartExit"): - self.__removeAllButWhitelisted() - - def setFlashCookies(self, cookies): - """ - Public method to set the list of cached Flash cookies. - - @param cookies list of Flash cookies to store - @type list of FlashCookie - """ - self.__flashCookies = cookies[:] - - def flashCookies(self): - """ - Public method to get the list of cached Flash cookies. - - @return list of Flash cookies - @rtype list of FlashCookie - """ - if not self.__flashCookies: - self.__loadFlashCookies() - - return self.__flashCookies[:] - - def newCookiesList(self): - """ - Public method to get the list of newly detected Flash cookies. - - @return list of newly detected Flash cookies - @rtype list of str - """ - return self.__newCookiesList[:] - - def clearNewOrigins(self): - """ - Public method to clear the list of newly detected Flash cookies. - """ - self.__newCookiesList = [] - - def clearCache(self): - """ - Public method to clear the list of cached Flash cookies. - """ - self.__flashCookies = [] - - def __isBlacklisted(self, cookie): - """ - Private method to check for a blacklisted cookie. - - @param cookie Flash cookie to be tested - @type FlashCookie - @return flag indicating a blacklisted cookie - @rtype bool - """ - return ( - cookie.origin in Preferences.getWebBrowser("FlashCookiesBlacklist") - ) - - def __isWhitelisted(self, cookie): - """ - Private method to check for a whitelisted cookie. - - @param cookie Flash cookie to be tested - @type FlashCookie - @return flag indicating a whitelisted cookie - @rtype bool - """ - return ( - cookie.origin in Preferences.getWebBrowser("FlashCookiesWhitelist") - ) - - def __removeAllButWhitelisted(self): - """ - Private method to remove all non-whitelisted cookies. - """ - for cookie in self.__flashCookies[:]: - if not self.__isWhitelisted(cookie): - self.removeCookie(cookie) - - def removeAllCookies(self): - """ - Public method to remove all flash cookies. - """ - for cookie in self.__flashCookies[:]: - self.removeCookie(cookie) - self.clearNewOrigins() - self.clearCache() - - def __sharedObjectDirName(self): - """ - Private slot to determine the path of the shared data objects. - - @return path of the shared data objects - @rtype str - """ - if ( - "macromedia" in self.flashPlayerDataPath().lower() or - "/.gnash" not in self.flashPlayerDataPath().lower() - ): - return "/#SharedObjects/" - else: - return "/SharedObjects/" - - def flashPlayerDataPath(self): - """ - Public method to get the Flash Player data path. - - @return Flash Player data path - @rtype str - """ - return Preferences.getWebBrowser("FlashCookiesDataPath") - - def preferencesChanged(self): - """ - Public slot to handle a change of preferences. - """ - self.__startStopTimer() - - def removeCookie(self, cookie): - """ - Public method to remove a cookie of the list of cached cookies. - - @param cookie Flash cookie to be removed - @type FlashCookie - """ - if cookie in self.__flashCookies: - self.__flashCookies.remove(cookie) - shutil.rmtree(cookie.path, True) - - def __autoRefresh(self): - """ - Private slot to refresh the list of cookies. - """ - if ( - self.__flashCookieManagerDialog and - self.__flashCookieManagerDialog.isVisible() - ): - return - - oldFlashCookies = self.__flashCookies[:] - self.__loadFlashCookies() - newCookieList = [] - - for cookie in self.__flashCookies[:]: - if self.__isBlacklisted(cookie): - self.removeCookie(cookie) - continue - - if self.__isWhitelisted(cookie): - continue - - newCookie = True - for oldCookie in oldFlashCookies: - if (oldCookie.path + oldCookie.name == - cookie.path + cookie.name): - newCookie = False - break - - if newCookie: - newCookieList.append(cookie.path + "/" + cookie.name) - - if newCookieList and Preferences.getWebBrowser("FlashCookieNotify"): - self.__newCookiesList.extend(newCookieList) - win = WebBrowser.WebBrowserWindow.WebBrowserWindow.mainWindow() - if win is None: - return - - view = win.currentBrowser() - if view is None: - return - - from .FlashCookieNotification import FlashCookieNotification - notification = FlashCookieNotification( - view, self, len(newCookieList)) - notification.show() - - def showFlashCookieManagerDialog(self): - """ - Public method to show the Flash cookies management dialog. - """ - if self.__flashCookieManagerDialog is None: - from .FlashCookieManagerDialog import FlashCookieManagerDialog - self.__flashCookieManagerDialog = FlashCookieManagerDialog(self) - - self.__flashCookieManagerDialog.refreshView() - self.__flashCookieManagerDialog.showPage(0) - self.__flashCookieManagerDialog.show() - self.__flashCookieManagerDialog.raise_() - - def __startStopTimer(self): - """ - Private slot to start or stop the auto refresh timer. - """ - if Preferences.getWebBrowser("FlashCookieAutoRefresh"): - if not self.__timer.isActive(): - if not bool(self.__flashCookies): - self.__loadFlashCookies() - - self.__timer.start() - else: - self.__timer.stop() - - def __loadFlashCookies(self): - """ - Private slot to load the Flash cookies to be cached. - """ - self.__flashCookies = [] - self.__loadFlashCookiesFromPath(self.flashPlayerDataPath()) - - def __loadFlashCookiesFromPath(self, path): - """ - Private slot to load the Flash cookies from a path. - - @param path Flash cookies path - @type str - """ - if path.endswith("#AppContainer"): - # specific to IE and Windows - return - - path = path.replace("\\", "/") - solDir = QDir(path) - entryList = solDir.entryList() - for entry in entryList: - if entry == "." or entry == "..": - continue - entryInfo = QFileInfo(path + "/" + entry) - if entryInfo.isDir(): - self.__loadFlashCookiesFromPath(entryInfo.filePath()) - else: - self.__insertFlashCookie(entryInfo.filePath()) - - def __insertFlashCookie(self, path): - """ - Private method to insert a Flash cookie into the cache. - - @param path Flash cookies path - @type str - """ - solFile = QFile(path) - if not solFile.open(QFile.ReadOnly): - return - - dataStr = "" - data = bytes(solFile.readAll()) - if data: - try: - reader = FlashCookieReader() - reader.setBytes(data) - reader.parse() - dataStr = reader.toString() - except FlashCookieReaderError as err: - dataStr = err.msg - - solFileInfo = QFileInfo(solFile) - - cookie = FlashCookie() - cookie.contents = dataStr - cookie.name = solFileInfo.fileName() - cookie.path = solFileInfo.canonicalPath() - cookie.size = int(solFile.size()) - cookie.lastModified = solFileInfo.lastModified() - cookie.origin = self.__extractOriginFrom(path) - - self.__flashCookies.append(cookie) - - def __extractOriginFrom(self, path): - """ - Private method to extract the cookie origin given its file name. - - @param path file name of the cookie file - @type str - @return cookie origin - @rtype str - """ - origin = path - if path.startswith( - self.flashPlayerDataPath() + self.__sharedObjectDirName()): - origin = origin.replace( - self.flashPlayerDataPath() + self.__sharedObjectDirName(), "") - if "/" in origin: - origin = origin.split("/", 1)[1] - elif path.startswith( - self.flashPlayerDataPath() + - "/macromedia.com/support/flashplayer/sys/"): - origin = origin.replace( - self.flashPlayerDataPath() + - "/macromedia.com/support/flashplayer/sys/", "") - if origin == "settings.sol": - return self.tr("!default") - elif origin.startswith("#"): - origin = origin[1:] - else: - origin = "" - - index = origin.find("/") - if index == -1: - return self.tr("!other") - - origin = origin[:index] - if origin in ["localhost", "local"]: - origin = "!localhost" - - return origin
--- a/eric6/WebBrowser/FlashCookieManager/FlashCookieManagerDialog.py Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,425 +0,0 @@ -# -*- coding: utf-8 -*- - -# Copyright (c) 2015 - 2021 Detlev Offenbach <detlev@die-offenbachs.de> -# - -""" -Module implementing a dialog to manage the flash cookies. -""" - -from PyQt5.QtCore import pyqtSlot, Qt, QPoint, QTimer -from PyQt5.QtWidgets import ( - QDialog, QTreeWidgetItem, QApplication, QMenu, QInputDialog, QLineEdit -) - -from E5Gui import E5MessageBox -from E5Gui.E5OverrideCursor import E5OverrideCursor - -from .Ui_FlashCookieManagerDialog import Ui_FlashCookieManagerDialog - -import Preferences -import UI.PixmapCache - - -class FlashCookieManagerDialog(QDialog, Ui_FlashCookieManagerDialog): - """ - Class implementing a dialog to manage the flash cookies. - """ - def __init__(self, manager, parent=None): - """ - Constructor - - @param manager reference to the Flash cookie manager object - @type FlashCookieManager - @param parent reference to the parent widget - @type QWidget - """ - super(FlashCookieManagerDialog, self).__init__(parent) - self.setupUi(self) - self.setWindowFlags(Qt.Window) - - self.cookiesList.setContextMenuPolicy(Qt.CustomContextMenu) - self.cookiesList.customContextMenuRequested.connect( - self.__cookiesListContextMenuRequested) - - self.__manager = manager - - @pyqtSlot() - def on_whiteList_itemSelectionChanged(self): - """ - Private slot handling the selection of items in the whitelist. - """ - enable = len(self.whiteList.selectedItems()) > 0 - self.removeWhiteButton.setEnabled(enable) - - @pyqtSlot() - def on_blackList_itemSelectionChanged(self): - """ - Private slot handling the selection of items in the blacklist. - """ - enable = len(self.blackList.selectedItems()) > 0 - self.removeBlackButton.setEnabled(enable) - - @pyqtSlot() - def on_removeWhiteButton_clicked(self): - """ - Private slot to remove a server from the whitelist. - """ - for itm in self.whiteList.selectedItems(): - row = self.whiteList.row(itm) - self.whiteList.takeItem(row) - del itm - - @pyqtSlot() - def on_addWhiteButton_clicked(self): - """ - Private slot to add a server to the whitelist. - """ - origin, ok = QInputDialog.getText( - self, - self.tr("Add to whitelist"), - self.tr("Origin:"), - QLineEdit.Normal) - if ok and bool(origin): - self.__addWhitelist(origin) - - def __addWhitelist(self, origin): - """ - Private method to add a cookie origin to the whitelist. - - @param origin origin to be added to the list - @type str - """ - if not origin: - return - - if len(self.blackList.findItems(origin, Qt.MatchFixedString)) > 0: - E5MessageBox.information( - self, - self.tr("Add to whitelist"), - self.tr("""The server '{0}' is already in the blacklist.""" - """ Please remove it first.""").format(origin)) - return - - if len(self.whiteList.findItems(origin, Qt.MatchFixedString)) == 0: - self.whiteList.addItem(origin) - - @pyqtSlot() - def on_removeBlackButton_clicked(self): - """ - Private slot to remove a server from the blacklist. - """ - for itm in self.blackList.selectedItems(): - row = self.blackList.row(itm) - self.blackList.takeItem(row) - del itm - - @pyqtSlot() - def on_addBlackButton_clicked(self): - """ - Private slot to add a server to the blacklist. - """ - origin, ok = QInputDialog.getText( - self, - self.tr("Add to blacklist"), - self.tr("Origin:"), - QLineEdit.Normal) - if ok and bool(origin): - self.__addBlacklist(origin) - - def __addBlacklist(self, origin): - """ - Private method to add a cookie origin to the blacklist. - - @param origin origin to be added to the list - @type str - """ - if not origin: - return - - if len(self.whiteList.findItems(origin, Qt.MatchFixedString)) > 0: - E5MessageBox.information( - self, - self.tr("Add to blacklist"), - self.tr("""The server '{0}' is already in the whitelist.""" - """ Please remove it first.""").format(origin)) - return - - if len(self.blackList.findItems(origin, Qt.MatchFixedString)) == 0: - self.blackList.addItem(origin) - - @pyqtSlot(str) - def on_filterEdit_textChanged(self, filterStr): - """ - Private slot to filter the cookies list. - - @param filterStr filter text - @type str - """ - if not filterStr: - # show all in collapsed state - for index in range(self.cookiesList.topLevelItemCount()): - self.cookiesList.topLevelItem(index).setHidden(False) - self.cookiesList.topLevelItem(index).setExpanded(False) - else: - # show matching in expanded state - filterStr = filterStr.lower() - for index in range(self.cookiesList.topLevelItemCount()): - txt = ( - "." + - self.cookiesList.topLevelItem(index).text(0).lower() - ) - self.cookiesList.topLevelItem(index).setHidden( - filterStr not in txt) - self.cookiesList.topLevelItem(index).setExpanded(True) - - @pyqtSlot(QTreeWidgetItem, QTreeWidgetItem) - def on_cookiesList_currentItemChanged(self, current, previous): - """ - Private slot handling a change of the current cookie item. - - @param current reference to the current item - @type QTreeWidgetItem - @param previous reference to the previous item - @type QTreeWidgetItem - """ - if current is None: - self.removeButton.setEnabled(False) - return - - cookie = current.data(0, Qt.UserRole) - if cookie is None: - self.nameLabel.setText(self.tr("<no flash cookie selected>")) - self.sizeLabel.setText(self.tr("<no flash cookie selected>")) - self.originLabel.setText(self.tr("<no flash cookie selected>")) - self.modifiedLabel.setText(self.tr("<no flash cookie selected>")) - self.contentsEdit.clear() - self.pathEdit.clear() - self.removeButton.setText(self.tr("Remove Cookie Group")) - else: - suffix = "" - if cookie.path.startswith( - self.__manager.flashPlayerDataPath() + - "/macromedia.com/support/flashplayer/sys"): - suffix = self.tr(" (settings)") - self.nameLabel.setText( - self.tr("{0}{1}", "name and suffix") - .format(cookie.name, suffix)) - self.sizeLabel.setText(self.tr("{0} Byte").format(cookie.size)) - self.originLabel.setText(cookie.origin) - self.modifiedLabel.setText( - cookie.lastModified.toString("yyyy-MM-dd hh:mm:ss")) - self.contentsEdit.setPlainText(cookie.contents) - self.pathEdit.setText(cookie.path) - self.removeButton.setText(self.tr("Remove Cookie")) - self.removeButton.setEnabled(True) - - @pyqtSlot(QPoint) - def __cookiesListContextMenuRequested(self, pos): - """ - Private slot handling the cookies list context menu. - - @param pos position to show the menu at - @type QPoint - """ - itm = self.cookiesList.itemAt(pos) - if itm is None: - return - - menu = QMenu() - addBlacklistAct = menu.addAction(self.tr("Add to blacklist")) - addWhitelistAct = menu.addAction(self.tr("Add to whitelist")) - - self.cookiesList.setCurrentItem(itm) - - activatedAction = menu.exec( - self.cookiesList.viewport().mapToGlobal(pos)) - if itm.childCount() == 0: - origin = itm.data(0, Qt.UserRole).origin - else: - origin = itm.text(0) - - if activatedAction == addBlacklistAct: - self.__addBlacklist(origin) - elif activatedAction == addWhitelistAct: - self.__addWhitelist(origin) - - @pyqtSlot() - def on_reloadButton_clicked(self): - """ - Private slot handling a press of the reload button. - """ - self.refreshView(True) - - @pyqtSlot() - def on_removeAllButton_clicked(self): - """ - Private slot to remove all cookies. - """ - ok = E5MessageBox.yesNo( - self, - self.tr("Remove All"), - self.tr("""Do you really want to delete all flash cookies on""" - """ your computer?""")) - if ok: - cookies = self.__manager.flashCookies() - for cookie in cookies: - self.__manager.removeCookie(cookie) - - self.cookiesList.clear() - self.__manager.clearNewOrigins() - self.__manager.clearCache() - - @pyqtSlot() - def on_removeButton_clicked(self): - """ - Private slot to remove one cookie or a cookie group. - """ - itm = self.cookiesList.currentItem() - if itm is None: - return - - cookie = itm.data(0, Qt.UserRole) - if cookie is None: - # remove a whole cookie group - origin = itm.text(0) - cookieList = self.__manager.flashCookies() - for fcookie in cookieList: - if fcookie.origin == origin: - self.__manager.removeCookie(fcookie) - - index = self.cookiesList.indexOfTopLevelItem(itm) - self.cookiesList.takeTopLevelItem(index) - else: - self.__manager.removeCookie(cookie) - parent = itm.parent() - index = parent.indexOfChild(itm) - parent.takeChild(index) - - if parent.childCount() == 0: - # remove origin item as well - index = self.cookiesList.indexOfTopLevelItem(parent) - self.cookiesList.takeTopLevelItem(index) - del parent - del itm - - def refreshView(self, forceReload=False): - """ - Public method to refresh the dialog view. - - @param forceReload flag indicating to reload the cookies - @type bool - """ - blocked = self.filterEdit.blockSignals(True) - self.filterEdit.clear() - self.contentsEdit.clear() - self.filterEdit.blockSignals(blocked) - - if forceReload: - self.__manager.clearCache() - self.__manager.clearNewOrigins() - - QTimer.singleShot(0, self.__refreshCookiesList) - QTimer.singleShot(0, self.__refreshFilterLists) - - def showPage(self, index): - """ - Public method to display a given page. - - @param index index of the page to be shown - @type int - """ - self.cookiesTabWidget.setCurrentIndex(index) - - @pyqtSlot() - def __refreshCookiesList(self): - """ - Private slot to refresh the cookies list. - """ - with E5OverrideCursor(): - cookies = self.__manager.flashCookies() - self.cookiesList.clear() - - counter = 0 - originDict = {} - for cookie in cookies: - cookieOrigin = cookie.origin - if cookieOrigin.startswith("."): - cookieOrigin = cookieOrigin[1:] - - if cookieOrigin in originDict: - itm = QTreeWidgetItem(originDict[cookieOrigin]) - else: - newParent = QTreeWidgetItem(self.cookiesList) - newParent.setText(0, cookieOrigin) - newParent.setIcon(0, UI.PixmapCache.getIcon("dirOpen")) - self.cookiesList.addTopLevelItem(newParent) - originDict[cookieOrigin] = newParent - - itm = QTreeWidgetItem(newParent) - - suffix = "" - if cookie.path.startswith( - self.__manager.flashPlayerDataPath() + - "/macromedia.com/support/flashplayer/sys"): - suffix = self.tr(" (settings)") - - if cookie.path + "/" + cookie.name in ( - self.__manager.newCookiesList() - ): - suffix += self.tr(" [new]") - font = itm.font(0) - font.setBold(True) - itm.setFont(font) - itm.parent().setExpanded(True) - - itm.setText(0, self.tr("{0}{1}", "name and suffix").format( - cookie.name, suffix)) - itm.setData(0, Qt.UserRole, cookie) - - counter += 1 - if counter > 100: - QApplication.processEvents() - counter = 0 - - self.removeAllButton.setEnabled( - self.cookiesList.topLevelItemCount() > 0) - self.removeButton.setEnabled(False) - - @pyqtSlot() - def __refreshFilterLists(self): - """ - Private slot to refresh the white and black lists. - """ - self.whiteList.clear() - self.blackList.clear() - - self.whiteList.addItems( - Preferences.getWebBrowser("FlashCookiesWhitelist")) - self.blackList.addItems( - Preferences.getWebBrowser("FlashCookiesBlacklist")) - - self.on_whiteList_itemSelectionChanged() - self.on_blackList_itemSelectionChanged() - - def closeEvent(self, evt): - """ - Protected method to handle the close event. - - @param evt reference to the close event - @type QCloseEvent - """ - self.__manager.clearNewOrigins() - - whiteList = [] - for row in range(self.whiteList.count()): - whiteList.append(self.whiteList.item(row).text()) - - blackList = [] - for row in range(self.blackList.count()): - blackList.append(self.blackList.item(row).text()) - - Preferences.setWebBrowser("FlashCookiesWhitelist", whiteList) - Preferences.setWebBrowser("FlashCookiesBlacklist", blackList) - - evt.accept()
--- a/eric6/WebBrowser/FlashCookieManager/FlashCookieManagerDialog.ui Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,478 +0,0 @@ -<?xml version="1.0" encoding="UTF-8"?> -<ui version="4.0"> - <class>FlashCookieManagerDialog</class> - <widget class="QDialog" name="FlashCookieManagerDialog"> - <property name="geometry"> - <rect> - <x>0</x> - <y>0</y> - <width>550</width> - <height>500</height> - </rect> - </property> - <property name="windowTitle"> - <string>Flash Cookie Management</string> - </property> - <property name="sizeGripEnabled"> - <bool>true</bool> - </property> - <layout class="QVBoxLayout" name="verticalLayout"> - <item> - <widget class="QTabWidget" name="cookiesTabWidget"> - <property name="currentIndex"> - <number>0</number> - </property> - <widget class="QWidget" name="tab"> - <attribute name="title"> - <string>Stored Flash Cookies</string> - </attribute> - <layout class="QGridLayout" name="gridLayout_4"> - <item row="0" column="0"> - <layout class="QGridLayout" name="gridLayout"> - <item row="0" column="0"> - <widget class="QLabel" name="label_4"> - <property name="text"> - <string>Filter:</string> - </property> - </widget> - </item> - <item row="0" column="1"> - <widget class="QLineEdit" name="filterEdit"> - <property name="toolTip"> - <string>Enter cookie filter string</string> - </property> - </widget> - </item> - <item row="1" column="0" colspan="2"> - <widget class="QLabel" name="label_24"> - <property name="text"> - <string>Stored Flash Cookies:</string> - </property> - <property name="wordWrap"> - <bool>true</bool> - </property> - </widget> - </item> - <item row="2" column="0" colspan="2"> - <widget class="QTreeWidget" name="cookiesList"> - <property name="alternatingRowColors"> - <bool>true</bool> - </property> - <column> - <property name="text"> - <string>Origin</string> - </property> - </column> - </widget> - </item> - </layout> - </item> - <item row="0" column="1"> - <layout class="QGridLayout" name="gridLayout_3"> - <item row="0" column="0"> - <spacer name="horizontalSpacer"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>158</width> - <height>20</height> - </size> - </property> - </spacer> - </item> - <item row="0" column="1"> - <widget class="QPushButton" name="reloadButton"> - <property name="toolTip"> - <string>Press to reload Flash cookies from disk</string> - </property> - <property name="text"> - <string>Reload</string> - </property> - </widget> - </item> - <item row="1" column="0" colspan="2"> - <layout class="QGridLayout" name="gridLayout_2"> - <item row="0" column="0"> - <widget class="QLabel" name="label_6"> - <property name="sizePolicy"> - <sizepolicy hsizetype="Fixed" vsizetype="Preferred"> - <horstretch>0</horstretch> - <verstretch>0</verstretch> - </sizepolicy> - </property> - <property name="text"> - <string>Name:</string> - </property> - <property name="alignment"> - <set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set> - </property> - </widget> - </item> - <item row="0" column="1"> - <widget class="QLabel" name="nameLabel"> - <property name="text"> - <string><no flash cookie selected></string> - </property> - </widget> - </item> - <item row="1" column="0"> - <widget class="QLabel" name="labelSize_2"> - <property name="text"> - <string>Size:</string> - </property> - </widget> - </item> - <item row="1" column="1"> - <widget class="QLabel" name="sizeLabel"> - <property name="text"> - <string><no flash cookie selected></string> - </property> - </widget> - </item> - <item row="2" column="0"> - <widget class="QLabel" name="label_7"> - <property name="text"> - <string>Origin:</string> - </property> - </widget> - </item> - <item row="2" column="1"> - <widget class="QLabel" name="originLabel"> - <property name="text"> - <string><no flash cookie selected></string> - </property> - </widget> - </item> - <item row="3" column="0"> - <widget class="QLabel" name="label_22"> - <property name="text"> - <string>Last Modified:</string> - </property> - </widget> - </item> - <item row="3" column="1"> - <widget class="QLabel" name="modifiedLabel"> - <property name="text"> - <string><no flash cookie selected></string> - </property> - </widget> - </item> - </layout> - </item> - <item row="2" column="0" colspan="2"> - <widget class="QLabel" name="label"> - <property name="text"> - <string>Contents:</string> - </property> - </widget> - </item> - <item row="3" column="0" colspan="2"> - <widget class="QPlainTextEdit" name="contentsEdit"> - <property name="tabChangesFocus"> - <bool>true</bool> - </property> - <property name="lineWrapMode"> - <enum>QPlainTextEdit::NoWrap</enum> - </property> - <property name="readOnly"> - <bool>true</bool> - </property> - <property name="textInteractionFlags"> - <set>Qt::TextSelectableByKeyboard|Qt::TextSelectableByMouse</set> - </property> - </widget> - </item> - </layout> - </item> - <item row="1" column="0" colspan="2"> - <layout class="QHBoxLayout" name="horizontalLayout_2"> - <item> - <widget class="QLabel" name="label_2"> - <property name="text"> - <string>Path:</string> - </property> - </widget> - </item> - <item> - <widget class="QLineEdit" name="pathEdit"> - <property name="readOnly"> - <bool>true</bool> - </property> - </widget> - </item> - </layout> - </item> - <item row="2" column="0" colspan="2"> - <layout class="QHBoxLayout" name="horizontalLayout"> - <item> - <widget class="QPushButton" name="removeAllButton"> - <property name="toolTip"> - <string>Press to remove all flash cookies</string> - </property> - <property name="text"> - <string>Remove All Cookies</string> - </property> - </widget> - </item> - <item> - <widget class="QPushButton" name="removeButton"> - <property name="toolTip"> - <string>Press to remove selected flash cookies</string> - </property> - <property name="text"> - <string>Remove Cookie</string> - </property> - </widget> - </item> - <item> - <spacer name="horizontalSpacer_2"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>40</width> - <height>20</height> - </size> - </property> - </spacer> - </item> - </layout> - </item> - </layout> - </widget> - <widget class="QWidget" name="tab_2"> - <attribute name="title"> - <string>Flash Cookies Lists</string> - </attribute> - <layout class="QGridLayout" name="gridLayout_5"> - <item row="0" column="0"> - <widget class="QLabel" name="label_3"> - <property name="text"> - <string><b>Flash cookie whitelist</b></string> - </property> - </widget> - </item> - <item row="0" column="1"> - <widget class="QLabel" name="label_5"> - <property name="text"> - <string><b>Flash cookie blacklist</b></string> - </property> - </widget> - </item> - <item row="1" column="0"> - <widget class="QLabel" name="label_17"> - <property name="text"> - <string>Flash cookies from these origins will not be deleted automatically. (Also detection of them will not be notified to user.)</string> - </property> - <property name="wordWrap"> - <bool>true</bool> - </property> - </widget> - </item> - <item row="1" column="1"> - <widget class="QLabel" name="label_18"> - <property name="text"> - <string>Flash cookies from these origins will be deleted without any notification.</string> - </property> - <property name="wordWrap"> - <bool>true</bool> - </property> - </widget> - </item> - <item row="2" column="0"> - <widget class="QListWidget" name="whiteList"> - <property name="alternatingRowColors"> - <bool>true</bool> - </property> - <property name="selectionMode"> - <enum>QAbstractItemView::ExtendedSelection</enum> - </property> - <property name="sortingEnabled"> - <bool>true</bool> - </property> - </widget> - </item> - <item row="2" column="1"> - <widget class="QListWidget" name="blackList"> - <property name="alternatingRowColors"> - <bool>true</bool> - </property> - <property name="selectionMode"> - <enum>QAbstractItemView::ExtendedSelection</enum> - </property> - <property name="sortingEnabled"> - <bool>true</bool> - </property> - </widget> - </item> - <item row="3" column="0"> - <layout class="QHBoxLayout" name="horizontalLayout_3"> - <item> - <spacer name="horizontalSpacer_3"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>40</width> - <height>20</height> - </size> - </property> - </spacer> - </item> - <item> - <widget class="QPushButton" name="removeWhiteButton"> - <property name="toolTip"> - <string>Press to remove selected origins from the whitelist</string> - </property> - <property name="text"> - <string>Remove</string> - </property> - </widget> - </item> - <item> - <widget class="QPushButton" name="addWhiteButton"> - <property name="toolTip"> - <string>Press to add an origin to the whitelist</string> - </property> - <property name="text"> - <string>Add...</string> - </property> - </widget> - </item> - <item> - <spacer name="horizontalSpacer_4"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>40</width> - <height>20</height> - </size> - </property> - </spacer> - </item> - </layout> - </item> - <item row="3" column="1"> - <layout class="QHBoxLayout" name="horizontalLayout_4"> - <item> - <spacer name="horizontalSpacer_5"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>40</width> - <height>20</height> - </size> - </property> - </spacer> - </item> - <item> - <widget class="QPushButton" name="removeBlackButton"> - <property name="toolTip"> - <string>Press to remove selected origins from the blacklist</string> - </property> - <property name="text"> - <string>Remove</string> - </property> - </widget> - </item> - <item> - <widget class="QPushButton" name="addBlackButton"> - <property name="toolTip"> - <string>Press to add an origin to the blacklist</string> - </property> - <property name="text"> - <string>Add...</string> - </property> - </widget> - </item> - <item> - <spacer name="horizontalSpacer_6"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="sizeHint" stdset="0"> - <size> - <width>40</width> - <height>20</height> - </size> - </property> - </spacer> - </item> - </layout> - </item> - </layout> - </widget> - </widget> - </item> - <item> - <widget class="QDialogButtonBox" name="buttonBox"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - <property name="standardButtons"> - <set>QDialogButtonBox::Close</set> - </property> - </widget> - </item> - </layout> - </widget> - <tabstops> - <tabstop>cookiesTabWidget</tabstop> - <tabstop>filterEdit</tabstop> - <tabstop>cookiesList</tabstop> - <tabstop>reloadButton</tabstop> - <tabstop>contentsEdit</tabstop> - <tabstop>pathEdit</tabstop> - <tabstop>removeAllButton</tabstop> - <tabstop>removeButton</tabstop> - <tabstop>whiteList</tabstop> - <tabstop>removeWhiteButton</tabstop> - <tabstop>addWhiteButton</tabstop> - <tabstop>blackList</tabstop> - <tabstop>removeBlackButton</tabstop> - <tabstop>addBlackButton</tabstop> - </tabstops> - <resources/> - <connections> - <connection> - <sender>buttonBox</sender> - <signal>accepted()</signal> - <receiver>FlashCookieManagerDialog</receiver> - <slot>accept()</slot> - <hints> - <hint type="sourcelabel"> - <x>248</x> - <y>254</y> - </hint> - <hint type="destinationlabel"> - <x>157</x> - <y>274</y> - </hint> - </hints> - </connection> - <connection> - <sender>buttonBox</sender> - <signal>rejected()</signal> - <receiver>FlashCookieManagerDialog</receiver> - <slot>reject()</slot> - <hints> - <hint type="sourcelabel"> - <x>316</x> - <y>260</y> - </hint> - <hint type="destinationlabel"> - <x>286</x> - <y>274</y> - </hint> - </hints> - </connection> - </connections> -</ui>
--- a/eric6/WebBrowser/FlashCookieManager/FlashCookieNotification.py Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,65 +0,0 @@ -# -*- coding: utf-8 -*- - -# Copyright (c) 2015 - 2021 Detlev Offenbach <detlev@die-offenbachs.de> -# - -""" -Module implementing the feature permission bar widget. -""" - -from PyQt5.QtWidgets import QLabel, QHBoxLayout, QPushButton - -from E5Gui.E5AnimatedWidget import E5AnimatedWidget - -import UI.PixmapCache - - -class FlashCookieNotification(E5AnimatedWidget): - """ - Class implementing the feature permission bar widget. - """ - DefaultHeight = 30 - - def __init__(self, view, manager, noCookies): - """ - Constructor - - @param view reference to the web view - @type WebBrowserView - @param manager reference to the Flash cookie manager object - @type FlashCookieManager - @param noCookies number of newly detected Flash cookies - @type int - """ - super(FlashCookieNotification, self).__init__(parent=view) - - self.__manager = manager - - if noCookies == 1: - msg = self.tr("A new flash cookie was detected.") - else: - msg = self.tr( - "{0} new flash cookies were detected." - ).format(noCookies) - self.setAutoFillBackground(True) - self.__layout = QHBoxLayout() - self.setLayout(self.__layout) - self.__layout.setContentsMargins(9, 0, 0, 0) - self.__iconLabel = QLabel(self) - self.__iconLabel.setPixmap(UI.PixmapCache.getPixmap("flashCookie")) - self.__layout.addWidget(self.__iconLabel) - self.__messageLabel = QLabel(msg, self) - self.__layout.addWidget(self.__messageLabel) - self.__viewButton = QPushButton(self.tr("View"), self) - self.__layout.addWidget(self.__viewButton) - self.__layout.addStretch() - self.__discardButton = QPushButton(UI.PixmapCache.getIcon("close"), - "", self) - self.__layout.addWidget(self.__discardButton) - - self.__viewButton.clicked.connect(manager.showFlashCookieManagerDialog) - self.__viewButton.clicked.connect(self.hide) - self.__discardButton.clicked.connect(self.hide) - - self.resize(view.width(), self.height()) - self.startAnimation()
--- a/eric6/WebBrowser/FlashCookieManager/FlashCookieReader.py Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,474 +0,0 @@ -# -*- coding: utf-8 -*- - -# Copyright (c) 2015 - 2021 Detlev Offenbach <detlev@die-offenbachs.de> -# - -""" -Module implementing a class to read flash cookies. -""" - -# -# Note: The code is based on s2x.py -# - -import struct -import io - -from PyQt5.QtCore import QDateTime - - -class FlashCookieReaderError(Exception): - """ - Class containing data of a reader error. - """ - def __init__(self, msg): - """ - Constructor - - @param msg error message - @type str - """ - self.msg = msg - - -class FlashCookieReader(object): - """ - Class implementing a reader for flash cookies (*.sol files). - """ - Number = b'\x00' - Boolean = b'\x01' - String = b'\x02' - ObjObj = b'\x03' - Null = b'\x05' - Undef = b'\x06' - ObjArr = b'\x08' - ObjDate = b'\x0B' - ObjM = b'\x0D' - ObjXml = b'\x0F' - ObjCc = b'\x10' - - EpochCorrectionMsecs = 31 * 24 * 60 * 60 * 1000 - # Flash Epoch starts at 1969-12-01 - - def __init__(self): - """ - Constructor - """ - self.__result = {} - # dictionary with element name as key and tuple of - # type and value as value - self.__data = None - self.__parsed = False - - def setBytes(self, solData): - """ - Public method to set the contents of a sol file to be parsed. - - @param solData contents of the file - @type bytes - """ - self.__data = io.BytesIO(solData) - - def setFileName(self, solFilename): - """ - Public method to set the name of a sol file to be parsed. - - @param solFilename name of the sol file - @type str - """ - self.__data = open(solFilename, "rb") - - def setFile(self, solFile): - """ - Public method to set an open sol file to be parsed. - - @param solFile sol file to be parsed - @type io.FileIO - """ - self.__data = solFile - - def parse(self): - """ - Public method to parse the sol file. - - @exception FlashCookieReaderError raised when encountering a parse - issue - """ - if self.__data is None: - return - - self.__data.seek(0, 2) - lenSolData = self.__data.tell() - self.__data.seek(0) - self.__data.read(2) - sLenData = self.__data.read(4) - if len(sLenData) != 4: - raise FlashCookieReaderError("Flash cookie is invalid.") - lenData, = struct.unpack(">L", sLenData) # unsigned long, big-endian - if lenSolData != lenData + 6: - raise FlashCookieReaderError( - "Flash cookie data lengths don't match\n" - " file length: {0}\n" - " data length: {1}" - .format(lenSolData - 6, lenData)) - sDataType = self.__data.read(4).decode("utf-8") # 'TCSO' - if sDataType != "TCSO": - raise FlashCookieReaderError( - "Flash cookie type is not 'TCSO'; found '{0}'." - .format(sDataType)) - self.__data.read(6) - lenSolName, = struct.unpack(">H", self.__data.read(2)) - # unsigned short, big-endian - solName = self.__data.read(lenSolName) - solName = solName.decode("utf-8", "replace") - self.__result["SolName"] = ("string", solName) - self.__data.read(4) - while self.__data.tell() < lenSolData: - lenVariableName, = struct.unpack(">H", self.__data.read(2)) - # unsigned short, big-endian - variableName = self.__data.read(lenVariableName) - variableName = variableName.decode("utf-8", "replace") - variableType = self.__data.read(1) - if len(variableType): - if variableType == self.Number: - self.__parseNumber(variableName, self.__result) - elif variableType == self.Boolean: - self.__parseBoolean(variableName, self.__result) - elif variableType == self.String: - self.__parseString(variableName, self.__result) - elif variableType == self.ObjObj: - self.__parseObject(variableName, self.__result) - elif variableType == self.ObjArr: - self.__parseArray(variableName, self.__result) - elif variableType == self.ObjDate: - self.__parseDate(variableName, self.__result) - elif variableType == self.ObjXml: - self.__parseXml(variableName, self.__result) - elif variableType == self.ObjCc: - self.__parseOcc(variableName, self.__result) - elif variableType == self.ObjM: - self.__parseOjm(variableName, self.__result) - elif variableType == self.Null: - self.__parseNull(variableName, self.__result) - elif variableType == self.Undef: - self.__parseUndefined(variableName, self.__result) - else: - raise FlashCookieReaderError( - "Unexpected Data Type: " + hex(ord(variableType))) - self.__data.read(1) # '\x00' - self.__data.close() - self.__parsed = True - - def __parseNumber(self, variableName, parent): - """ - Private method to parse a number. - - @param variableName name of the variable to be parsed - @type str - @param parent reference to the dictionary to insert the result into - @type dict - """ - b = self.__data.read(8) - if b == b"\x7F\xF0\x00\x00\x00\x00\x00\x00": - value = "Infinity" - elif b == b"\xFF\xF0\x00\x00\x00\x00\x00\x00": - value = "-Infinity" - elif b == b"\x7F\xF8\x00\x00\x00\x00\x00\x00": - value = "NaN" - else: - value, = struct.unpack(">d", b) # double, big-endian - value = str(value) - parent[variableName] = ("number", value) - - def __parseBoolean(self, variableName, parent): - """ - Private method to parse a boolean. - - @param variableName name of the variable to be parsed - @type str - @param parent reference to the dictionary to insert the result into - @type dict - """ - b = self.__data.read(1) - if b == b"\x00": - value = "False" - elif b == b"\x01": - value = "True" - else: - # boolean value error; default to True - value = "True" - parent[variableName] = ("boolean", value) - - def __parseString(self, variableName, parent): - """ - Private method to parse a string. - - @param variableName name of the variable to be parsed - @type str - @param parent reference to the dictionary to insert the result into - @type dict - """ - lenStr, = struct.unpack(">H", self.__data.read(2)) - # unsigned short, big-endian - b = self.__data.read(lenStr) - value = b.decode("utf-8", "replace") - parent[variableName] = ("string", value) - - def __parseDate(self, variableName, parent): - """ - Private method to parse a date. - - @param variableName name of the variable to be parsed - @type str - @param parent reference to the dictionary to insert the result into - @type dict - """ - msec, = struct.unpack(">d", self.__data.read(8)) - # double, big-endian - # DateObject: Milliseconds Count From Dec. 1, 1969 - msec -= self.EpochCorrectionMsecs # correct for Unix epoch - minOffset, = struct.unpack(">h", self.__data.read(2)) - # short, big-endian - offset = minOffset // 60 # offset in hours - # Timezone is UTC + Offset - value = QDateTime() - value.setMSecsSinceEpoch(msec) - value.setOffsetFromUtc(offset * 3600) - parent[variableName] = ("date", - value.toString("yyyy-MM-dd HH:mm:ss t")) - - def __parseXml(self, variableName, parent): - """ - Private method to parse XML. - - @param variableName name of the variable to be parsed - @type str - @param parent reference to the dictionary to insert the result into - @type dict - """ - lenCData, = struct.unpack(">L", self.__data.read(4)) - # unsigned long, big-endian - cData = self.__data.read(lenCData) - value = cData.decode("utf-8", "replace") - parent[variableName] = ("xml", value) - - def __parseOjm(self, variableName, parent): - """ - Private method to parse an m_object. - - @param variableName name of the variable to be parsed - @type str - @param parent reference to the dictionary to insert the result into - @type dict - """ - parent[variableName] = ("m_object", "") - - def __parseNull(self, variableName, parent): - """ - Private method to parse a null object. - - @param variableName name of the variable to be parsed - @type str - @param parent reference to the dictionary to insert the result into - @type dict - """ - parent[variableName] = ("null", "") - - def __parseUndefined(self, variableName, parent): - """ - Private method to parse an undefined object. - - @param variableName name of the variable to be parsed - @type str - @param parent reference to the dictionary to insert the result into - @type dict - """ - parent[variableName] = ("undefined", "") - - def __parseObject(self, variableName, parent): - """ - Private method to parse an object. - - @param variableName name of the variable to be parsed - @type str - @param parent reference to the dictionary to insert the result into - @type dict - @exception FlashCookieReaderError raised when an issue with the cookie - file is found - """ - value = {} - parent[variableName] = ("object", value) - - lenVariableName, = struct.unpack(">H", self.__data.read(2)) - # unsigned short, big-endian - while lenVariableName != 0: - variableName = self.__data.read(lenVariableName) - variableName = variableName.decode("utf-8", "replace") - variableType = self.__data.read(1) - if variableType == self.Number: - self.__parseNumber(variableName, value) - elif variableType == self.Boolean: - self.__parseBoolean(variableName, value) - elif variableType == self.String: - self.__parseString(variableName, value) - elif variableType == self.ObjObj: - self.__parseObject(variableName, value) - elif variableType == self.ObjArr: - self.__parseArray(variableName, value) - elif variableType == self.ObjDate: - self.__parseDate(variableName, value) - elif variableType == self.ObjXml: - self.__parseXml(variableName, value) - elif variableType == self.ObjCc: - self.__parseOcc(variableName, value) - elif variableType == self.ObjM: - self.__parseOjm(variableName, value) - elif variableType == self.Null: - self.__parseNull(variableName, value) - elif variableType == self.Undef: - self.__parseUndefined(variableName, value) - else: - raise FlashCookieReaderError( - "Unexpected Data Type: " + hex(ord(variableType))) - lenVariableName, = struct.unpack(">H", self.__data.read(2)) - self.__data.read(1) # '\x09' - - def __parseArray(self, variableName, parent): - """ - Private method to parse an array. - - @param variableName name of the variable to be parsed - @type str - @param parent reference to the dictionary to insert the result into - @type dict - @exception FlashCookieReaderError raised when an issue with the cookie - file is found - """ - arrayLength, = struct.unpack(">L", self.__data.read(4)) - # unsigned long, big-endian - - value = {} - parent[variableName] = ("array; length={0}".format(arrayLength), value) - - lenVariableName, = struct.unpack(">H", self.__data.read(2)) - # unsigned short, big-endian - while lenVariableName != 0: - variableName = self.__data.read(lenVariableName) - variableName = variableName.decode("utf-8", "replace") - variableType = self.__data.read(1) - if variableType == self.Number: - self.__parseNumber(variableName, value) - elif variableType == self.Boolean: - self.__parseBoolean(variableName, value) - elif variableType == self.String: - self.__parseString(variableName, value) - elif variableType == self.ObjObj: - self.__parseObject(variableName, value) - elif variableType == self.ObjArr: - self.__parseArray(variableName, value) - elif variableType == self.ObjDate: - self.__parseDate(variableName, value) - elif variableType == self.ObjXml: - self.__parseXml(variableName, value) - elif variableType == self.ObjCc: - self.__parseOcc(variableName, value) - elif variableType == self.ObjM: - self.__parseOjm(variableName, value) - elif variableType == self.Null: - self.__parseNull(variableName, value) - elif variableType == self.Undef: - self.__parseUndefined(variableName, value) - else: - raise FlashCookieReaderError( - "Unexpected Data Type: " + hex(ord(variableType))) - lenVariableName, = struct.unpack(">H", self.__data.read(2)) - self.__data.read(1) # '\x09' - - def __parseOcc(self, variableName, parent): - """ - Private method to parse a c_object. - - @param variableName name of the variable to be parsed - @type str - @param parent reference to the dictionary to insert the result into - @type dict - @exception FlashCookieReaderError raised when an issue with the cookie - file is found - """ - lenCname = struct.unpack(">H", self.__data.read(2)) - # unsigned short, big-endian - cname = self.__data.read(lenCname) - cname = cname.decode("utf-8", "replace") - - value = {} - parent[variableName] = ("c_object; cname={0}".format(cname), value) - - lenVariableName, = struct.unpack(">H", self.__data.read(2)) - # unsigned short, big-endian - while lenVariableName != 0: - variableName = self.__data.read(lenVariableName) - variableName = variableName.decode("utf-8", "replace") - variableType = self.__data.read(1) - if variableType == self.Number: - self.__parseNumber(variableName, value) - elif variableType == self.Boolean: - self.__parseBoolean(variableName, value) - elif variableType == self.String: - self.__parseString(variableName, value) - elif variableType == self.ObjObj: - self.__parseObject(variableName, value) - elif variableType == self.ObjArr: - self.__parseArray(variableName, value) - elif variableType == self.ObjDate: - self.__parseDate(variableName, value) - elif variableType == self.ObjXml: - self.__parseXml(variableName, value) - elif variableType == self.ObjCc: - self.__parseOcc(variableName, value) - elif variableType == self.ObjM: - self.__parseOjm(variableName, value) - elif variableType == self.Null: - self.__parseNull(variableName, value) - elif variableType == self.Undef: - self.__parseUndefined(variableName, value) - else: - raise FlashCookieReaderError( - "Unexpected Data Type: " + hex(ord(variableType))) - lenVariableName, = struct.unpack(">H", self.__data.read(2)) - self.__data.read(1) # '\x09' - - def toString(self, indent=0, parent=None): - """ - Public method to convert the parsed cookie to a string representation. - - @param indent indentation level - @type int - @param parent reference to the dictionary to be converted - @type dict - @return string representation of the cookie - @rtype str - """ - indentStr = " " * indent - strArr = [] - - if parent is None: - parent = self.__result - - if not parent: - return "" - - for variableName in sorted(parent.keys()): - variableType, value = parent[variableName] - if isinstance(value, dict): - resultStr = self.toString(indent + 1, value) - if resultStr: - strArr.append("{0}{1}:\n{2}" - .format(indentStr, variableName, resultStr)) - else: - strArr.append("{0}{1}:" - .format(indentStr, variableName)) - else: - strArr.append("{0}{1}: {2}" - .format(indentStr, variableName, value)) - - return "\n".join(strArr)
--- a/eric6/WebBrowser/FlashCookieManager/FlashCookieUtilities.py Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,57 +0,0 @@ -# -*- coding: utf-8 -*- - -# Copyright (c) 2015 - 2021 Detlev Offenbach <detlev@die-offenbachs.de> -# - -""" -Module implementing some utility functions. -""" - -import os - -from PyQt5.QtCore import QProcessEnvironment - -import Globals - - -def flashDataPathForOS(): - """ - Function to determine the OS dependent path where Flash cookies - are stored. - - @return Flash data path - @rtype str - """ - # On Microsoft Windows NT 5.x and 6.x, they are stored in: - # %APPDATA%\Macromedia\Flash Player\#SharedObjects\ - # %APPDATA%\Macromedia\Flash Player\macromedia.com\support\flashplayer\sys\ - # On Mac OS X, they are stored in: - # ~/Library/Preferences/Macromedia/Flash Player/#SharedObjects/ - # ~/Library/Preferences/Macromedia/Flash Player/macromedia.com/support/⏎ - # flashplayer/sys/ - # On Linux or Unix, they are stored in: - # ~/.macromedia/Flash_Player/#SharedObjects/ - # ~/.macromedia/Flash_Player/macromedia.com/support/flashplayer/sys/ - # For Linux and Unix systems, if the open-source Gnash plugin is being used - # instead of the official Adobe Flash, they will instead be found at: - # ~/.gnash/SharedObjects/ - - flashPath = "" - - if Globals.isWindowsPlatform(): - appData = QProcessEnvironment.systemEnvironment().value("APPDATA") - appData = appData.replace("\\", "/") - flashPath = appData + "/Macromedia/Flash Player" - elif Globals.isMacPlatform(): - flashPath = os.path.expanduser( - "~/Library/Preferences/Macromedia/Flash Player") - else: - if os.path.exists(os.path.expanduser("~/.macromedia")): - flashPath = os.path.expanduser("~/.macromedia/Flash_Player") - elif os.path.exists(os.path.expanduser("~/.gnash")): - flashPath = os.path.expanduser("~/.gnash") - - return flashPath - -# -# eflag: noqa = M891
--- a/eric6/WebBrowser/FlashCookieManager/__init__.py Thu Feb 04 14:38:33 2021 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,8 +0,0 @@ -# -*- coding: utf-8 -*- - -# Copyright (c) 2015 - 2021 Detlev Offenbach <detlev@die-offenbachs.de> -# - -""" -Package implementing the Flash cookie manager and associated objects. -"""
--- a/eric6/WebBrowser/WebBrowserClearPrivateDataDialog.py Thu Feb 04 14:38:33 2021 +0100 +++ b/eric6/WebBrowser/WebBrowserClearPrivateDataDialog.py Thu Feb 04 14:59:13 2021 +0100 @@ -37,7 +37,7 @@ @return tuple with flags indicating which data to clear (browsing history, search history, favicons, disk cache, cookies, - passwords, web databases, downloads, flash, zoom values, SSL + passwords, web databases, downloads, zoom values, SSL certificate error exceptions) and the selected history period in milliseconds (tuple of booleans and integer) """ @@ -66,7 +66,6 @@ self.passwordsCheckBox.isChecked(), self.databasesCheckBox.isChecked(), self.downloadsCheckBox.isChecked(), - self.flashCookiesCheckBox.isChecked(), self.zoomCheckBox.isChecked(), self.sslExceptionsCheckBox.isChecked(), historyPeriod)
--- a/eric6/WebBrowser/WebBrowserClearPrivateDataDialog.ui Thu Feb 04 14:38:33 2021 +0100 +++ b/eric6/WebBrowser/WebBrowserClearPrivateDataDialog.ui Thu Feb 04 14:59:13 2021 +0100 @@ -7,7 +7,7 @@ <x>0</x> <y>0</y> <width>305</width> - <height>380</height> + <height>378</height> </rect> </property> <property name="windowTitle"> @@ -197,23 +197,6 @@ </widget> </item> <item> - <widget class="Line" name="line"> - <property name="orientation"> - <enum>Qt::Horizontal</enum> - </property> - </widget> - </item> - <item> - <widget class="QCheckBox" name="flashCookiesCheckBox"> - <property name="toolTip"> - <string>Select to clear cookies set by the Adobe Flash Player</string> - </property> - <property name="text"> - <string>Cookies from Adobe &Flash Player</string> - </property> - </widget> - </item> - <item> <widget class="QDialogButtonBox" name="buttonBox"> <property name="orientation"> <enum>Qt::Horizontal</enum> @@ -237,7 +220,6 @@ <tabstop>databasesCheckBox</tabstop> <tabstop>zoomCheckBox</tabstop> <tabstop>sslExceptionsCheckBox</tabstop> - <tabstop>flashCookiesCheckBox</tabstop> </tabstops> <resources/> <connections>
--- a/eric6/WebBrowser/WebBrowserWindow.py Thu Feb 04 14:38:33 2021 +0100 +++ b/eric6/WebBrowser/WebBrowserWindow.py Thu Feb 04 14:59:13 2021 +0100 @@ -98,7 +98,6 @@ _greaseMonkeyManager = None _notification = None _featurePermissionManager = None - _flashCookieManager = None _imageSearchEngine = None _autoScroller = None _tabManager = None @@ -439,8 +438,6 @@ self.__virusTotal.fileScanReport.connect( self.__virusTotalFileScanReport) - self.flashCookieManager() - e5App().focusChanged.connect(self.__appFocusChanged) self.__toolbarStates = self.saveState() @@ -1371,21 +1368,6 @@ self.__showCookiesConfiguration) self.__actions.append(self.cookiesAct) - self.flashCookiesAct = E5Action( - self.tr('Flash Cookies'), - UI.PixmapCache.getIcon("flashCookie"), - self.tr('&Flash Cookies...'), 0, 0, self, - 'webbrowser_flash_cookies') - self.flashCookiesAct.setStatusTip(self.tr( - 'Manage flash cookies')) - self.flashCookiesAct.setWhatsThis(self.tr( - """<b>Flash Cookies</b>""" - """<p>Show a dialog to manage the flash cookies.</p>""" - )) - self.flashCookiesAct.triggered.connect( - self.__showFlashCookiesManagement) - self.__actions.append(self.flashCookiesAct) - self.personalDataAct = E5Action( self.tr('Personal Information'), UI.PixmapCache.getIcon("pim"), @@ -2038,7 +2020,6 @@ menu.addSeparator() menu.addAction(self.acceptedLanguagesAct) menu.addAction(self.cookiesAct) - menu.addAction(self.flashCookiesAct) menu.addAction(self.personalDataAct) menu.addAction(self.greaseMonkeyAct) menu.addAction(self.featurePermissionAct) @@ -2165,7 +2146,6 @@ menu.addSeparator() menu.addAction(self.acceptedLanguagesAct) menu.addAction(self.cookiesAct) - menu.addAction(self.flashCookiesAct) menu.addAction(self.personalDataAct) menu.addAction(self.greaseMonkeyAct) menu.addAction(self.featurePermissionAct) @@ -2335,7 +2315,6 @@ settingstb.addAction(self.shortcutsAct) settingstb.addAction(self.acceptedLanguagesAct) settingstb.addAction(self.cookiesAct) - settingstb.addAction(self.flashCookiesAct) settingstb.addAction(self.personalDataAct) settingstb.addAction(self.greaseMonkeyAct) settingstb.addAction(self.featurePermissionAct) @@ -2924,8 +2903,6 @@ WebIconProvider.instance().close() - self.flashCookieManager().shutdown() - if len(WebBrowserWindow.BrowserWindows) == 1: # it is the last window self.tabManager().close() @@ -3292,12 +3269,6 @@ dlg = CookiesConfigurationDialog(self) dlg.exec() - def __showFlashCookiesManagement(self): - """ - Private slot to show the flash cookies management dialog. - """ - self.flashCookieManager().showFlashCookieManagerDialog() - @classmethod def setUseQtHelp(cls, use): """ @@ -3654,9 +3625,10 @@ dlg = WebBrowserClearPrivateDataDialog(self) if dlg.exec() == QDialog.Accepted: # browsing history, search history, favicons, disk cache, cookies, - # passwords, web databases, downloads, Flash cookies + # passwords, web databases, downloads, zoom values, SSL error + # exceptions, history period (history, searches, favicons, cache, cookies, - passwords, databases, downloads, flashCookies, zoomValues, + passwords, databases, downloads, zoomValues, sslExceptions, historyPeriod) = dlg.getData() if history: self.historyManager().clear(historyPeriod) @@ -3681,8 +3653,6 @@ self.webProfile().cookieStore().deleteAllCookies() if passwords: self.passwordManager().clear() - if flashCookies: - self.flashCookieManager().removeAllCookies() if zoomValues: ZoomManager.instance().clear() if sslExceptions: @@ -3980,22 +3950,6 @@ return cls._featurePermissionManager @classmethod - def flashCookieManager(cls): - """ - Class method to get a reference to the flash cookies manager. - - @return reference to the flash cookies manager - @rtype FlashCookieManager - """ - if cls._flashCookieManager is None: - from .FlashCookieManager.FlashCookieManager import ( - FlashCookieManager - ) - cls._flashCookieManager = FlashCookieManager() - - return cls._flashCookieManager - - @classmethod def imageSearchEngine(cls): """ Class method to get a reference to the image search engine.