| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
| |
When the push method in DAV baclend is called with a nonexistent source
file, the `GLib-GObject-CRITICAL **: 12:07:04.743: g_object_unref:
assertion 'G_IS_OBJECT (object)' failed` message is printed because
the `g_object_unref` function is called for a `NULL` pointer. Let's
use `g_clear_object` instead to avoid this.
|
|
|
|
|
|
|
|
|
|
|
| |
When the username is not part of an URI, then the following message is
printed: `GVFS-CRITICAL **: 12:31:47.663: g_mount_spec_set_with_len_internal:
assertion 'value != NULL' failed`. This is because `g_mount_spec_set` is
called with `NULL`. It possibly lead to crash when it is build with the
`G_DISABLE_CHECKS` option. This bug was introduced recently by the commit
6636d89f. Let's check the value before setting it to fix this.
Related: https://gitlab.gnome.org/GNOME/gvfs/-/issues/644
|
|
|
|
|
|
|
|
|
| |
The recent commits break build when Avahi support is disabled. Let's add
the missing ifdef directive and move some variable declarations to fix
the build. Part of this change was originally proposed by the reporter of
GNOME/gvfs#621.
Fixes: https://gitlab.gnome.org/GNOME/gvfs/-/issues/621
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently, it is not possible to connect to some Nextcloud servers when
a username is part of URI. So this also affects volumes configured over
GOA. The main problem seems to be that Nextcloud doesn't send the
`WWW-Authenticate` header as a part of 401 response in certain cases (e.g.
when 2FA is enabled). A recent libsoup change leads to the situation that
DAV backend doesn't have a chance to specify a password as the `authenticate`
signal is not called at all. This is because libsoup tries to authenticate
with an empty password first. Let's drop the username from URI to avoid the
password-less login attempt so the backend has at least one chance to try
some password in this case...
Fixes: https://gitlab.gnome.org/GNOME/gvfs/-/issues/617
|
|
|
|
|
|
|
|
|
|
| |
The mount operation hangs for DNS-SD style URIs (i.e. with `dav+sd` and
`davs+sd` schemes) after the recent commit 9203fad5. This is because the
backend now uses the asynchronous APIs, but the `GVfsDnsSdResolver` is still
used synchronously. Let's use asynchronous API for the resolver as well to
fix the hangs.
Fixes: https://gitlab.gnome.org/GNOME/gvfs/-/issues/618
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Since libsoup3 cannot deal with threads, we cannot use the do_
methods which execute in a thread pool. However, we can implement
these in an async manner, which will bypass the thread pool and
get rid of the issue.
The write methods are left synchronous as they deal with a memory
output stream and do not actually call libsoup. Therefore, we do
not have to care whether they are threaded or not.
Fixes: https://gitlab.gnome.org/GNOME/gvfs/-/issues/609
|
|
|
|
|
|
|
|
|
|
| |
The use of g_uri_build was also bad, since otherwise we would
run into this: https://gitlab.gnome.org/GNOME/glib/-/issues/2619
While this should be fixed in glib, we need to work around this
behavior for existing installations.
Fixes: https://gitlab.gnome.org/GNOME/gvfs/-/issues/614
|
|
|
|
|
|
|
|
|
| |
The `mount_base` uri is unreffed twice. First time over the local `mount_base`
pointer and for the second time over the `G_VFS_BACKEND_HTTP (backend)->mount_base`
pointer. This leads to `SIGABRT` from the `__pthread_kill_implementation`
function. Let's remove that extra unref to fix this crashes.
Fixes: https://bugzilla.redhat.com/show_bug.cgi?id=2066717
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The dav and http backends of the daemon now use libsoup3. Things
should work more or less the same as before.
One caveat is that the soup session no longer defaults to
ssl-strict, so it will no longer silently accept certificates.
This does not affect the DAV backend (it has its own handling
which is replicated in the soup3 port) but it does affect the
http backend.
Fixes: https://gitlab.gnome.org/GNOME/gvfs/-/issues/208
|
|
|
|
|
|
|
| |
It can be correctly implied from the value of filesystem::remote for
many backends, but let's make it explicit for them too.
Fixes https://gitlab.gnome.org/GNOME/gvfs/-/issues/497
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The layout of the modal dialogs in gnome-shell changed [1] and the title
now is larger and uses the style of a headline. Make sure all titles
remain fully visible and use shorter strings for those.
Also unify the generic "Enter password" strings a bit to make work
easier for translators and use this string for most cases:
"Authentication Required\nEnter password for “%s”:"
[1] https://gitlab.gnome.org/GNOME/gnome-shell/issues/1343
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Restoring files from the trash folder is slow in Nautilus as it attempts
to do it recursively. This is because G_IO_ERROR_NOT_SUPPORTED is
returned from g_file_move when G_FILE_COPY_NO_FALLBACK_FOR_MOVE flag is
used. The error is returned from client-side for pull/push operations
after commit 2e765449 as in the most cases the copy-and-delete approach
is really used there. But the problem is that it is not in all
cases, like in the trash backend case, where the native move operation
is used in fact. Let's handle the G_FILE_COPY_NO_FALLBACK_FOR_MOVE flag
directly in the backends, but not in the trash backend.
Fixes: https://gitlab.gnome.org/GNOME/nautilus/-/issues/1589
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The DAV backend tries to find the top-most directory when mounting.
Unfortunatelly, for example with nextcloud.com, the enumeration job
fails with `Method not allowed` error for the root directory found
by this logic:
```
<?xml version="1.0" encoding="utf-8"?>
<d:error xmlns:d="DAV:" xmlns:s="http://sabredav.org/ns">
<s:exception>Sabre\DAV\Exception\MethodNotAllowed</s:exception>
<s:message>Listing members of this collection is disabled</s:message>
</d:error>
```
This is because nextcloud.com prevents listing of its users. Let's
change the mount logic and always require info about children to be
sure that enumeration won't fail later.
Fixes: https://gitlab.gnome.org/GNOME/gvfs/-/issues/468
|
|
|
|
|
|
|
| |
Currently, only Basic and Digest authentication is possible for webdav
backend. Let's add support for NTLM also.
https://gitlab.gnome.org/GNOME/gvfs/issues/342
|
|
|
|
|
|
|
| |
Currently, only Basic and Digest authentication is possible for webdav
backend. Let's add support for Negotiate also.
https://gitlab.gnome.org/GNOME/gvfs/issues/342
|
|
|
|
|
|
| |
Don't ignore the result_uncertain flag from g_content_type_guess() as it
might cause nautilus to incorrectly think that a particular file is of a
certain type, and never check its magic.
|
|
|
|
|
|
|
|
|
|
| |
The mount operation currently fails with "Invalid argument" error if
GVfsDnsSdResolver returns link-local IPv6 address. This can quite easily
happen also when using File Share functionality provided by GNOME. It
fails because the link-local addresses requires interface to be specified.
Let's append the interface in them to fix this issue.
Fixes: https://gitlab.gnome.org/GNOME/gvfs/issues/423
|
|
|
|
|
|
| |
This is follow up of commit d8556a0, which removes brackets when mounting
over dav/davs schemes, however, the same fix is also needed when mounting
over dav+sd/davs+sd schemes in order to prevent "Invalid URI" error.
|
|
|
|
|
| |
GTimeVal is deprecated. Let's replace it by GDateTime in order to
prevent the deprecation warnings.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The recent commit e9653aa9, which allows mounting when 403 is returned
instead of 401, broke the backend for the case when authentication
succeeded for subdirectory and 403 is returned for the parent folder.
The backend doesn't work properly, even though it doesn't return any
error from the mount operation. Nautilus just shows "File is of unknown
type" and the backend prints errors like "soup_auth_authenticate:
assertion 'password != NULL' failed". Let's prevent usage of the
workaround from commit e9653aa9 after the first successful auth to fix
this issue.
Fixes: https://gitlab.gnome.org/GNOME/gvfs/issues/417
|
|
|
|
|
|
|
|
|
| |
GVfs uses different forms of "Operation not supported" string,
e.g. "Operation unsupported", "Operation not supported by
backend". Let's use "Operation not supported" consistently as
this is also used in GLib.
https://gitlab.gnome.org/GNOME/gvfs/issues/170
|
|
|
|
|
|
|
|
|
|
|
|
| |
Some servers e.g. davs://webdav.mc.gmx.net returns 403 status code
instead of 401 in case of invalid credentials. This causes that libsoup
fails immediately after the first login attempt, which is especially
problem in case of the wrong credentials stored in the keyring. A user
doesn't have any chance to manually specify correct credentials. Clear
the credentials cache and force libsoup to call the authentication
callback again...
Closes: https://gitlab.gnome.org/GNOME/gvfs/issues/351
|
|
|
|
| |
https://gitlab.gnome.org/GNOME/gvfs/issues/2
|
|
|
|
|
|
|
|
|
|
|
|
| |
Currently, the default value of max-conns-per-host libsoup property is
used, which causes dav backend lockups if two files are opened. I don't
see any easy solution how to prevent lockups, but we can definitely
reduce the chance of them by increasing max-conns properties. Much bigger
values are used by browsers nowadays. Hope that 32 is big enough for
regular use cases and small enough to not flood a server and not block
too much file descriptors...
Closes: https://gitlab.gnome.org/GNOME/gvfs/issues/6
|
|
|
|
|
|
|
|
|
|
| |
Most of the servers don't use "getcontentlength" node (which is used
to set file size) for directories anyway. However, some servers report
total size of files inside the directory, which is not expected and
causes issues for clients. Let's simply ignore file size for directories
if set.
https://gitlab.gnome.org/GNOME/nautilus/issues/431
|
|
|
|
|
|
|
|
|
|
| |
More warnings are printed when building thanks to meson port. The mounting
loop may be breaked before is_webdav variable is defined. Let's move the
initialization to another place in order to prevent usage of uninitialized
variable and the following warning:
warning: ‘is_webdav’ may be used uninitialized in this function
https://bugzilla.gnome.org/show_bug.cgi?id=786149
|
|
|
|
|
|
|
|
|
| |
More warnings are printed when building thanks to meson port. The bytes_avail
variable is guarded by have_bytes_avail, so it should not be used unitialized,
but let's initialize it for sure in order to prevent the following warning:
warning: ‘bytes_avail’ may be used uninitialized in this function
https://bugzilla.gnome.org/show_bug.cgi?id=786149
|
|
|
|
|
|
|
| |
Filesystem sizes can be large and in danger of overflowing. Guard
against that possibility in the dav and fuse FS query code.
https://bugzilla.gnome.org/show_bug.cgi?id=786177
|
|
|
|
|
|
|
|
|
|
|
| |
The "[]:" chars are omitted currently when encoding uri, because they
are valid for IPv6. This causes problems in some cases, e.g. output from
g_file_get_uri(g_file_new_for_uri("dav+sd://foo%3Abar._webdav._tcp.local"))
is "dav+sd://foo:bar._webdav._tcp.local/", which is obviously wrong. Add
gvfs_is_ipv6 in order to detect IPv6 addresses and encode also "[]:" chars
in other cases. Use gvfs_is_ipv6 to detect IPv6 also in some backends.
https://bugzilla.gnome.org/show_bug.cgi?id=772849
|
|
|
|
|
|
| |
See https://developer.gnome.org/hig/stable/typography.html
https://bugzilla.gnome.org/show_bug.cgi?id=772219
|
|
|
|
|
|
|
|
| |
Dav backend always tries to mount WebDAV share with the shortest prefix.
Unfortunately, it never tries the root when looking for it excepting
the case, when the root is already specified.
https://bugzilla.gnome.org/show_bug.cgi?id=770549
|
|
|
|
|
|
|
| |
If we have a DAV share, ie proper DAV header and good PROPFIND call
but we are not in a collection we report a better error message.
https://bugzilla.gnome.org/show_bug.cgi?id=770549
|
|
|
|
|
|
|
|
|
|
| |
If the user cancels the authentication dialog during the mount
operation, we should catch that case and instead of returing
G_IO_ERROR_FAILED we should G_IO_ERROR_FAILED_HANDLED. This will
prevent an (expected) error being back to the user. This is in
line with what other backends do in the same situation.
https://bugzilla.gnome.org/show_bug.cgi?id=770549
|
|
|
|
|
|
| |
Free the two messages use for mount root detection in case of error.
https://bugzilla.gnome.org/show_bug.cgi?id=770549
|
|
|
|
|
|
|
|
|
| |
If we can detect that a location is not a webdav share then prefer
that error message over any other. For other error cases also take
errors from the PROPFIND call into account. Translate the status
code into a proper GIO error code.
https://bugzilla.gnome.org/show_bug.cgi?id=770549
|
|
|
|
|
|
|
| |
Mark all network-based backends as remote. This is useful to remove
some hardcoded lists of filesystem types in GTK+.
Bump required GLib version accordingly.
|
|
|
|
|
|
|
|
|
| |
It is not possible to mount WebDAV share with IPv6 address currently.
GMountSpec host contains brackets around the IPv6 address, however SoupURI
doesn't. This patch handles this when converting GMountSpec to SoupURI
and vice versa.
https://bugzilla.gnome.org/show_bug.cgi?id=766631
|
|
|
|
|
|
| |
Otherwise nautilus will offer the wrong action in its UI.
https://bugzilla.gnome.org/show_bug.cgi?id=753934
|
|
|
|
|
|
|
| |
This attribute was being set inconsistently, and is used by the file
chooser.
https://bugzilla.gnome.org/show_bug.cgi?id=752834
|
|
|
|
|
|
|
|
|
|
| |
For progress in applications like Nautilus to be shown correctly, they
need at least one progress callback to be emitted at the end. This is
supposed to be guaranteed according to the GIO documentation. With
server-side copy and move using webdav, emit a single progress callback
at the end with the source file size.
https://bugzilla.gnome.org/show_bug.cgi?id=749354
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
When mounting a secure webdav share, verify the certificate using the
system certificate store, or if that is not possible, ask the user
whether it is OK.
ssl-strict is enabled for the SoupSession. If the first connection
attempt fails, the certificate is presented to the user. If they agree
to the certificate, then it is stored and compared with the certificate
presented on each subsequent connection. It is an error if the
certificate changes.
https://bugzilla.gnome.org/show_bug.cgi?id=708306
|
|
|
|
|
|
|
|
|
|
| |
Mime type octet-stream is set when writing since commit 635c3b5,
because soup_message_set_request requires to be called with mime type
and we don't know it. Unfortunatelly some servers returns this mime
type for written files instead of real mime type. Use
soup_message_body_append instead without mimetype to fix this issue.
https://bugzilla.gnome.org/show_bug.cgi?id=687757
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=744078
|
|
|
|
| |
https://bugzilla.gnome.org/show_bug.cgi?id=743379
|
|
|
|
|
|
|
| |
Don't leak the source and target URI when doing a server-side move.
Also, don't continue after giving an G_IO_ERROR_EXISTS.
https://bugzilla.gnome.org/show_bug.cgi?id=743379
|
|
|
|
|
|
|
|
| |
Use webdav's COPY method to implement support for server-side copying.
This improves performance considerably, especially over slow
connections.
https://bugzilla.gnome.org/show_bug.cgi?id=743379
|
|
|
|
|
|
|
|
|
| |
path_equal tries to unescape path before comparing. Unfortunately
this function is used also for already unescaped paths. Therefore
unescaping can fail. This commit reverts changes which was done in
commit 50af53d and unescape just uris, which aren't unescaped yet.
https://bugzilla.gnome.org/show_bug.cgi?id=743298
|
|
|
|
|
|
|
|
|
|
| |
Move operation fails immediately with G_IO_ERROR_CANT_CREATE_BACKUP if
G_FILE_COPY_BACKUP is specified. Consequently copy and delete fallback
isn't executed. Return NOT_SUPPORTED instead of CANT_CREATE_BACKUP to
proceed with the fallback if G_FILE_COPY_NO_FALLBACK_FOR_MOVE isn't
specified.
https://bugzilla.gnome.org/show_bug.cgi?id=740057
|
|
|
|
|
|
|
|
|
| |
When writing a large amount to a GMemoryOutputStream, the reallocation
function can fail. Use g_try_realloc so that failures generate
G_IO_ERROR_NO_SPACE rather than abort the process (as happens with
g_realloc).
https://bugzilla.gnome.org/show_bug.cgi?id=739428
|
|
|
|
|
|
|
|
|
|
| |
Ignore parameters of the file's content type since these break
applications which make use of the content type.
E.g. If the server returns a type such as "text/plain; charset=utf-8",
the file won't open in a text editor.
https://bugzilla.gnome.org/show_bug.cgi?id=676627
|