mirror of
https://github.com/dani-garcia/vaultwarden.git
synced 2026-03-01 03:10:51 +03:00
Refresh icons #159
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @quthla on GitHub (Dec 14, 2018).
Is there any way to refresh icons? Some of my entries only show the globe and there's no icon in icon_cache folder.
Maybe they should be refreshed when saving entries?
@mprasil commented on GitHub (Dec 14, 2018):
The icon_cache folder is the only cache, so if there's just globe, it failed to fetch the icons for some reason. You should be able to right click and copy image location in Vault and then try to load this in the browser. Try to F5 couple times and see what shows up in bitwarden_rs logs.
@quthla commented on GitHub (Dec 14, 2018):
So it seems there's no
/favicon.icobut the icon is referenced in the HTML as<link rel="shortcut icon" href="/images/ico/favicon32x32.ico" />I guess that's the reason why it's not being fetched as the HTML is not parsed?
@quthla commented on GitHub (Dec 14, 2018):
I think that's not the actual issue. Maybe there's some problem with rocket when it's receiving hundreds of requests. I removed all icons from icon_cache because when I manually opened the image urls as you said, it would fetch the icon.
There's like 60 icon requests after clearing icon_cache in network inspector with 0 byte response and not even response headers received from bitwarden_rs backend.
You could probably reproduce the issue by removing icon_cache and browser cache and then visit the vault.
@dani-garcia commented on GitHub (Dec 15, 2018):
By default we are using the official icon server (at https://icons.bitwarden.com). I have no idea how it works internally, but it must parse the HTML because some of the icons in my cache are higher resolution, and those are usually included in
<head>for mobile devices.I just tried deleting both caches and opening my personal account (with about 200 entries saved) and all the icons load correctly in about 30 seconds. The requests look stalled for some time while the server downloads the icons because server has a limited number of threads.
Do the icon requests hit the server for you? That would look something like this:
In the middle it would mention something like:
Downloading icon for <domain>@quthla commented on GitHub (Dec 15, 2018):
The problem is caused by the apache2 reverse proxy. Got many entries like this in the log
[proxy_http:error] [pid 1272:tid 140665737230080] (20014)Internal error (specific information not available): [client 1.1.1.1:32251] AH01102: error reading status line from remote server localhost:81, referer: https://server/Using an ssh tunnel directly the bitwarden_rs loads all icons.
@quthla commented on GitHub (Dec 15, 2018):
For some reason setting
disablereuse=onin the apache proxy configuration fixes the issue. Still unclear if rocket or apache is buggy there but at least it's working.@mprasil commented on GitHub (Dec 15, 2018):
The vault initially spins up a ton of requests. There was some issue reported upstream suggesting that only visible entries should load initially. Maybe you're hitting some limit in Apache?
@quthla commented on GitHub (Dec 15, 2018):
Problem seems to be that connection are reused thus setting
disablereuse=onin apache proxy config fixes the issue. Could be that rocket doesn't handle connection reuse so well but could also be a bug in apache.@BobWs commented on GitHub (Feb 10, 2019):
I have a similar problem with icon caching. This happened a few updates ago. I don't know exactly when. But when I check the log this is what I see.
} stdout 12:53:12 [2019-02-10 12:53:12][bitwarden_rs::api::icons][ERROR] Error downloading icon: ReqError. stdout 12:53:12 [CAUSE] Error { stdout 12:53:12 kind: Io( stdout 12:53:12 Custom { stdout 12:53:12 kind: WouldBlock, stdout 12:53:12 error: StringError( stdout 12:53:12 "timed out" stdout 12:53:12 ) stdout 12:53:12 } stdout 12:53:12 ), stdout 12:53:12 url: Some( stdout 12:53:12 "https://www.oneplus.com/favicon.ico" stdout 12:53:12 ) stdout 12:53:12 }Also when looking in the icon_cache folder I see the missing icons named like this:
www.oneplus.com.png.missAny idea how to fix this?