How to view cookies in safari 10? - macos

These are the approaches I have tried:
View HTTP headers in Safari 10, but the cookies is not showed there
I can find Cookies section under Storage Tab, but the Cookies are displayed in a table.
I would like to view the Cookies in a string rather than a table, is there any way except using another browser?

Go to the Console* tab. Type
document.cookie
which shows all cookies for this location.
*: to access the console, (credit #Geoff Crompton)
if [you] have the developer menu enabled, [you] can go to the Develop menu, choose Show Web Inspector, and in the bottom of the new window type document.cookie to see the cookies for the current website

Safari Version 14.0.3 (16610.4.3.1.4)
The Develop menu of Safari adds a variety of additional features to the web browser on the Mac, including the inspector and error consoles, javascript debugging tools, the ability to disable various page elements, enable the Do Not Track feature, use WebGL acceleration, and it offers a simple way to change the browsers user agent.
Develop menu in Safari:
Pull down the Safari menu and choose Preferences
Click on the Advanced tab
Check the box next to Show Develop menu in menu bar
Close Preferences, the Develop menu will now be visible between Bookmarks and Window menus

It will require a little fiddling, but there is a Python script here http://www.securitylearn.net/2012/10/27/cookies-binarycookies-reader/ that can dump the Binary Cookie format (located in ~/Library/Cookies/).

Related

Use Browser is missing settings like "Private" & "NewSession" in the Modern Design

For me that's a huge step back. The new Use Browser is missing settings like Private & NewSession in the Modern Design. So it's not possible to open Chrome in private mode anymore. So currently the only workaround is to hit CTRL+SHIFT+N as Chrome shortcut:
But for me that does not sound like a good solution as browsers can swap that hotkey or having different.
So before without the Modern Design is was possible to set incognito mode in Open Browser:
So why is that feature gone in the Modern Design rework? How to get it back without the workaround and still using the Modern Design?
Private coming 21.4
New session is gone forever because it was targeting IE only, which is out of support
There is a workaround that already allows the incognito mode now in Chrome:
Add Application/Browser
Add new Chrome Application to the Object Repository (or click Indicate application ...)
Now do NOT create a screen (if the Create screen window is now opened close it)
Select the Use Browser Chrome and go to property Unified Application Target > Arguments
Type in --incognito
Click on the Burger menu of Use Browser Chrome
In the dropdown select Add Screen to Object Repository
Create the Screen now
All done. When you now check Use Browser Chrome for the Unified Application Target > Arguments it should still say --incognito.

Safari Developer Tools: Preserve Network Log on Navigation

When using Safari Web Inspector to view the Network Log, the log is reset upon navigation, i.e. navigating to a different page clears the log.
In the Chrome Developer Tools, I can easily persist the network log by checking the "Preserve log" checkbox in the Network tab. In Firefox Developer Tools, I can preserve the network log by checking "Enable persistent logs" in the developer tools preferences.
With this persistence enabled, the network log remains intact until I manually clear the output, simplifying the process of tracking requests and redirects that happen during navigation to a new page.
Is there a similar feature in Safari Web Inspector?
In Safari 16.0 they have moved again:
In Safari 11.1.2 this is a setting on each tab under the checkbox "Preserve Log"
Note that if your Web Inspector window is too narrow to show all options, you'll have to expand it until it is wide enough to display the Preserve Log option, as mentioned in an answer by ShortFuse.
In Safari 11 this was in the Settings panel under "Network: Clear when page navigates", and it's sister setting "Console: Clear when page navigates".
There is a Preserve Log option in Network.
The problem is that if your window is too narrow, it disappears and Safari gives you no indication that it's there. Resize your Web Inspector window to be wider.
(That was a fun one to figure out!)
This was just added to WebKit last week: https://trac.webkit.org/changeset/211451
You can expect it to make it into a Safari Technology Preview build soon. Once it's in a build, you can toggle preserving logs on navigation in the Settings Tab.
It is the logo with a circle and 3 horizontal lines that preserves network tab -> preserve logs button, at least in Version 16.0

Is there a way to make the displayed tab in Firefox "follow" the opened Inspector window(s)?

When I am debugging frontend work, I frequently have multiple Inspector windows open at the same time, each inspecting a different page. As I change Inspector windows, I would like the displayed tab or window to follow me. In other words, I would like the browser to always automatically change to the page I am inspecting; I do not want to change Inspector windows, then go to the browser and find the corresponding tab or window myself.
Is this possible in Firefox? Is it possible in any browser?
(I realize I could dock the Inspector to each tab or window. I do not want to do that because I use the multiple Inspector windows side-by-side for comparison.)
While I am not aware of any way to switch to the target browser tab when selecting a given inspector window, you can certainly do it the other way around:
Say you have 3 tabs opened, and you have opened devtools for each them, in window-mode (undocked). Now, whenever you select any of these 3 tabs, if you just hit F12 (or ctrl+shift+I/cmd+alt+I), then the corresponding devtools window will be brought to the front.
That's an easy way to keep track of which devtools window is linked to which browser tab.
Now, doing this the other way around would require a new feature to be implemented. This can't really be automatic (or at least hidden behind a config of some sorts) because it could be considered frustrating to some users, having their current tab being switched away from each time they click in a devtools window.
I have filed this bug to get it done: https://bugzilla.mozilla.org/show_bug.cgi?id=1163646

Remove specific cookie on firefox

I am doing some testing of firefox and got myself into situation where I need some cookies to be present while some others to be removed. I could write javascript that would do this, but was wondering if there is a way to do it via UI, like it can be done on Chrome dev tools.
You can do this with a raw firefox:
First click on the small earth/lock logo at the left of the address:
Then click on "More informations"
In the popup, click "See the cookies"
In the second pop-up, you can selected and delete any cookie.
How do I remove specific cookies on firefox
You can do this with the Web Developer extension, which adds various web developer tools to the browser.
Right click on page
Select Web Developer
Select `Cookies
Select View Cookie Information
The resulting tab/window has options to Delete and Edit the cookies for the current web page.

What is the use of F12 key in Mozilla Firefox?

I think it is used to check the coding but when I tried it didn't respond. I mean it doesn't give any response and showing the data of current website.
F12 opens the built in Firefox Developer Tools in recent versions of Firefox. Press F12 again to close it. There is an extension to turn off the shortcut: https://addons.mozilla.org/en-US/firefox/addon/disable-f12-shortcut/
The f12 is a shortcut to Open up firebug in firefox. To open up firebug you must firstly have it installed
F12 is a standard Firefox shortcut that toggles the 'Firefox Developer Tools' on and off.
When you hit F12, Firefox's bottom half opens to show/reveal it's 'Developer Tools,' a Web Console (toolbox?), which
Logs information associated with a web page: network requests, JavaScript, CSS, security errors and warnings as well as error, warning and informational messages logged by JavaScript code running in the page.
Enables you to interact with a web page by executing JavaScript expressions in the context of the page.
It also has an inspector, a debugger, style editor, a profiler and more.
Again, F12 toggles it on and off.
Go to ≡ > Web Developer and you can see the menu of all it does and their shortcuts.
(Firebug was a free open-source web extension for Firefox that facilitated the live debugging, editing, and monitoring of any website's CSS, HTML, DOM, XHR, and JavaScript.
It was deprecated (replaced by something better) in favor of the integrated developer tools (F12) added to Firefox itself. As Firefox 57 no longer supports XUL add-ons, Firebug is no longer compatible.)
F12 is not bound to anything in Firefox - see Keyboard shortcuts. You are probably thinking of the Firebug addon which opens with that key.
The built-in Page Inspector in Firefox (v10 onwards) is accessed with Ctrl+Shift+I and then Alt+M.
In newer versions of Firefox (I have 91.12.0esr), there is an
"experimental" setting in the about:config configuration page that can disable the F12 hotkey (https://bugzilla.mozilla.org/show_bug.cgi?id=1630228)
Setting the devtools.experiment.f12.shortcut_disabled key to true causes the F12 key to bring up a temporary text box that says "To use the F12 shortcut, first open DevTools via the Web Developer menu." but thankfully no longer opens the DevTools bar.
This should be the default behavior, IMHO, since only a small fraction of users will know or care about viewing the HTML source of the page.

Resources