private String getCanonicalQuery(URI uri) {
        String query = uri.getQuery();
        if(query == null || query.isEmpty()) {
            return "";
        }
        List<NameValuePair> params = URLEncodedUtils.parse(query, StandardCharsets.UTF_8);
        Collections.sort(params, new Comparator<NameValuePair>() {
            @Override
            public int compare(NameValuePair l, NameValuePair r) {
                return l.getName().compareToIgnoreCase(r.getName());
            }
        });
        return URLEncodedUtils.format(params, StandardCharsets.UTF_8);
    }
Task 4.
<a href="https://docs.aws.amazon.com/general/latest/gr/sigv4-add-signature-to-request.html">Add the Signing Information to the Request</a>
src/main/java/io/fabric8/maven/docker/access/ecr/AwsSigner4.java