Opened 8 years ago

Closed 8 years ago

#659 closed defect (fixed)

"update-smart-drivedb" uses old sourceforge HTTP link

Reported by: ackackack Owned by: Christian Franke
Priority: minor Milestone: Release 6.5
Component: drivedb Version: 6.4
Keywords: Cc:


When curl is used in the drivedb update script it does not follow the redirect as given by sourceforge for http to https

Curl can be told to follow redirects with the -L option

Here is a simple patch that seems to solve this issue:

@@ -77,7 +77,7 @@
 for t in $os_dltools; do
   if which $t >/dev/null 2>/dev/null; then
     case $t in
-      curl)  DOWNLOAD="curl ${q:+-s }"'-f -o "$" "$SRC"' ;;
+      curl)  DOWNLOAD="curl -L ${q:+-s }"'-f -o "$" "$SRC"' ;;
       lynx)  DOWNLOAD='lynx -source "$SRC" >"$"' ;;
       wget)  DOWNLOAD="wget $q"'-O "$" "$SRC"' ;;
       fetch) DOWNLOAD='fetch -o "$" "$SRC"' ;; # FreeBSD

As an alternative the URL for the updates could be modified to look to https instead of http:

@@ -40,7 +40,7 @@

 # Download URL for sourceforge code browser

 # Parse options
 q="-q "

Change History (3)

comment:1 by Alex Samorukov, 8 years ago

I think its a good idea to switch to HTTPS - we had to use http because SF was not supporting https for anonymous fetch for a very long time.

comment:2 by Christian Franke, 8 years ago

Keywords: drivedb update curl redirect removed
Milestone: Release 6.5
Owner: set to Christian Franke
Status: newaccepted
Summary: "update-smart-drivedb" use of curl does not follow redirects"update-smart-drivedb" uses old sourceforge HTTP link

The reworked (r4180, r4181, r4182, r4184) version of update-smart-drivedb is not affected unless -u sf option is used. Redirects are disabled intentionally.

Leaving this ticket open because update-smart-drivedb -u sf should be fixed.

Note that the problem will never be fixed in Debian and Ubuntu packages as maintainers decided to remove the script, see Debian Bug #804299.

comment:3 by Christian Franke, 8 years ago

Resolution: fixed
Status: acceptedclosed
Note: See TracTickets for help on using tickets.