[elbe-devel] [PATCH] validation: use parent directories

Manuel Traut manuel.traut at linutronix.de
Tue Nov 21 06:50:47 CET 2017


Hi John,

On Mon, Nov 20, 2017 at 03:01:31PM +0100, John Ogness wrote:
> To validate repositories, elbe was checking for legacy
> per-component-and-architecture Release files. According to
> the Debian Repository Format documentation:
> 
>     "Clients must not use them."
> 
> And indeed, these legacy files are not found on the security
> servers.
> 
> Instead of the legacy Release files, just check if the parent
> directory is there.

applied to devel/elbe-3.0 and backported to devel/elbe-2.0

> NOTE: httpredir.debian.org does not support this. Do not use
>       this redirect service with elbe. Validating against a
>       redirect service is ridiculous anyway.

In the past we had examples in the repo using httpredir.

I'd like to have a check that 'httpredir' is not in an URL and print sth.
like this note as an error message.

What do you think?

  Manuel


> Signed-off-by: John Ogness <john.ogness at linutronix.de>
> ---
>  elbepack/elbexml.py | 14 +++-----------
>  1 file changed, 3 insertions(+), 11 deletions(-)
> 
> diff --git a/elbepack/elbexml.py b/elbepack/elbexml.py
> index 39eed4c7..297324c0 100644
> --- a/elbepack/elbexml.py
> +++ b/elbepack/elbexml.py
> @@ -179,18 +179,10 @@ class ElbeXML(object):
>  
>                  urls.append(s + "Release")
>                  if url_validation == ValidationMode.CHECK_ALL:
> -                    if l.startswith ("deb-src "):
> -                        urls.append(s + section + "/source/Release")
> -                    else:
> -                        if "updates" in suite:
> -                            urls.append(s + "/Release")
> -                        else:
> -                            urls.append(s + section + "/binary-%s/Release" % buildtype)
> +                    urls.append(s + section + "/source/")
> +                    urls.append(s + section + "/binary-%s/" % buildtype)
>                  elif url_validation == ValidationMode.CHECK_BINARIES:
> -                    if "updates" in suite:
> -                        urls.append(s + section + "/Release")
> -                    else:
> -                        urls.append(s + section + "/binary-%s/Release" % buildtype)
> +                    urls.append(s + section + "/binary-%s/" % buildtype)
>  
>          if not self.prj:
>              return
> -- 
> 2.14.0
> 
> _______________________________________________
> elbe-devel mailing list
> elbe-devel at linutronix.de
> https://lists.linutronix.de/mailman/listinfo/elbe-devel



More information about the elbe-devel mailing list