114 """ |
114 """ |
115 Private method to check for a blacklisted cookie. |
115 Private method to check for a blacklisted cookie. |
116 |
116 |
117 @param cookie Flash cookie to be tested |
117 @param cookie Flash cookie to be tested |
118 @type FlashCookie |
118 @type FlashCookie |
|
119 @return flag indicating a blacklisted cookie |
|
120 @rtype bool |
119 """ |
121 """ |
120 return cookie.origin in Preferences.getHelp("FlashCookiesBlacklist") |
122 return cookie.origin in Preferences.getHelp("FlashCookiesBlacklist") |
121 |
123 |
122 def __isWhitelisted(self, cookie): |
124 def __isWhitelisted(self, cookie): |
123 """ |
125 """ |
124 Private method to check for a whitelisted cookie. |
126 Private method to check for a whitelisted cookie. |
125 |
127 |
126 @param cookie Flash cookie to be tested |
128 @param cookie Flash cookie to be tested |
127 @type FlashCookie |
129 @type FlashCookie |
|
130 @return flag indicating a whitelisted cookie |
|
131 @rtype bool |
128 """ |
132 """ |
129 return cookie.origin in Preferences.getHelp("FlashCookiesWhitelist") |
133 return cookie.origin in Preferences.getHelp("FlashCookiesWhitelist") |
130 |
134 |
131 def __removeAllButWhitelisted(self): |
135 def __removeAllButWhitelisted(self): |
132 """ |
136 """ |
325 origin = origin.replace( |
329 origin = origin.replace( |
326 self.flashPlayerDataPath() + self.__sharedObjectDirName(), "") |
330 self.flashPlayerDataPath() + self.__sharedObjectDirName(), "") |
327 if "/" in origin: |
331 if "/" in origin: |
328 origin = origin.split("/", 1)[1] |
332 origin = origin.split("/", 1)[1] |
329 elif path.startswith( |
333 elif path.startswith( |
330 self.flashPlayerDataPath() + |
334 self.flashPlayerDataPath() + |
331 "/macromedia.com/support/flashplayer/sys/"): |
335 "/macromedia.com/support/flashplayer/sys/"): |
332 origin = origin.replace( |
336 origin = origin.replace( |
333 self.flashPlayerDataPath() + |
337 self.flashPlayerDataPath() + |
334 "/macromedia.com/support/flashplayer/sys/", "") |
338 "/macromedia.com/support/flashplayer/sys/", "") |
335 if origin == "settings.sol": |
339 if origin == "settings.sol": |
336 return self.tr("!default") |
340 return self.tr("!default") |
337 elif origin.startswith("#"): |
341 elif origin.startswith("#"): |
338 origin = origin[1:] |
342 origin = origin[1:] |