Skip to content

Commit

Permalink
šŸµšŸ¶šŸ»
Browse files Browse the repository at this point in the history
  • Loading branch information
alexsuter committed Dec 6, 2024
2 parents 5ab5ec2 + b86884e commit 2f5e1f8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>com.axonivy.connector.aws</groupId>
<artifactId>amazon-aws4-authenticator</artifactId>
<version>0.0.6-SNAPSHOT</version>
<version>0.0.7-SNAPSHOT</version>
<name>Amazon AWS 4 Authenticator</name>
<properties>
<maven.compiler.release>11</maven.compiler.release>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import static com.axonivy.connector.aws.authentication.Constants.SIGNED_HEADERS;
import static com.axonivy.connector.aws.authentication.Constants.X_AMZ_DATE;

import java.io.UnsupportedEncodingException;
import java.net.URLEncoder;
import java.nio.charset.StandardCharsets;

Expand Down Expand Up @@ -42,16 +43,15 @@ private void appendPath() {
path = "/";
}
try {
System.out.println(path);
var encodedPath = URLEncoder.encode(path, StandardCharsets.UTF_8.toString())
.replace("%2F", "/")
.replace("%7E", "~")
.replace("*", "%2A")
.replace("+", "%20");
.replace("%2F", "/")
.replace("%7E", "~")
.replace("*", "%2A")
.replace("+", "%20");
builder.append(encodedPath);
builder.append('\n');
} catch (Exception ex) {
throw new RuntimeException("Could not encode path " + path, ex);
} catch (UnsupportedEncodingException ex) {
throw new RuntimeException("Unable to encode path " + path, ex);
}
}

Expand Down

0 comments on commit 2f5e1f8

Please sign in to comment.