Skip to content

Commit

Permalink
new version 0.0.11:
Browse files Browse the repository at this point in the history
* self signed SSL certificate (issue #1): rename "Ignore" to "Trust" 
* add FAQ entry
  • Loading branch information
mhelleboid committed Nov 26, 2015
1 parent a793f7a commit c06e97a
Show file tree
Hide file tree
Showing 8 changed files with 24 additions and 24 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,14 +18,14 @@

# FAQ

**Is there any documentation available**
* **Is there any documentation available**
* Not yet

Not yet
* **What does "Sync" means**
* Right, it means "upload". This application will only upload new local images to your remote gallery


**What does "Sync" means**

Right, it means "upload". This application will only upload new local images to your remote gallery
* **Is there any link to [Piwigo Import Tree](http://piwigo.org/doc/doku.php?id=user_documentation:tools:piwigo_import_tree) ?**
* Yes. As of 0.0.x, we try to offer the same level of functionality. Right now, we use the same cache mechanism (upload each local file once based on it's filename)

# Troubleshooting

Expand Down
2 changes: 1 addition & 1 deletion remotesync-api/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@
<parent>
<groupId>piwigo</groupId>
<artifactId>remotesync</artifactId>
<version>0.0.10</version>
<version>0.0.11</version>
<relativePath>../remotesync</relativePath>
</parent>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public interface IClientConfiguration {
public String getProxyUsername();
public String getProxyPassword();

public boolean getIgnoreSelfSignedSSLCertificate();
public boolean getTrustSelfSignedSSLCertificate();

public int getChunkSize();
}
Original file line number Diff line number Diff line change
Expand Up @@ -180,7 +180,7 @@ protected CloseableHttpClient getHttpClient() throws Exception {
requestConfig = RequestConfig.custom().setProxy(proxy).build();
}

if (clientConfiguration.getIgnoreSelfSignedSSLCertificate()) {
if (clientConfiguration.getTrustSelfSignedSSLCertificate()) {
SSLContextBuilder sslContextBuilder = new SSLContextBuilder();
sslContextBuilder.loadTrustMaterial(null, new TrustSelfSignedStrategy());
httpClientBuilder.setSSLSocketFactory(new SSLConnectionSocketFactory(sslContextBuilder.build()));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -71,8 +71,8 @@ public class SyncConfiguration implements ISyncConfiguration {
protected String proxyPassword;

@Element(required = false)
@Option(name = "-isssc", usage = "ignore self signed ssl certificates")
protected String ignoreSelfSignedSSLCertificates = Boolean.FALSE.toString();
@Option(name = "-tsssc", usage = "trust self signed ssl certificates")
protected String trustSelfSignedSSLCertificates = Boolean.FALSE.toString();

@Element(required = false)
@Option(name = "-cs", usage = "chunk size (in Kbytes)")
Expand Down Expand Up @@ -177,16 +177,16 @@ public void setProxyPassword(String proxyPassword) {
this.proxyPassword = proxyPassword;
}

public boolean getIgnoreSelfSignedSSLCertificate() {
public boolean getTrustSelfSignedSSLCertificate() {
try {
return Boolean.parseBoolean(ignoreSelfSignedSSLCertificates);
return Boolean.parseBoolean(trustSelfSignedSSLCertificates);
} catch (Exception e) {
return false;
}
}

public void setIgnoreSelfSignedSSLCertificate(String string) {
this.ignoreSelfSignedSSLCertificates = string;
public void setTrustSelfSignedSSLCertificate(String string) {
this.trustSelfSignedSSLCertificates = string;
}

public int getChunkSize() {
Expand Down
4 changes: 2 additions & 2 deletions remotesync-ui/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
<dependency>
<groupId>piwigo</groupId>
<artifactId>remotesync-api</artifactId>
<version>0.0.10</version>
<version>0.0.11</version>
</dependency>
<dependency>
<groupId>org.apache.pivot</groupId>
Expand Down Expand Up @@ -73,7 +73,7 @@
<parent>
<groupId>piwigo</groupId>
<artifactId>remotesync</artifactId>
<version>0.0.10</version>
<version>0.0.11</version>
<relativePath>../remotesync</relativePath>
</parent>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ public class OptionsUI extends JFrame {
private JTextField proxyLogintextField;
private JTextField proxyPasswordtextField;
private JCheckBox chckbxUseProxy;
private JCheckBox chckbxISSSC;
private JCheckBox chckbxTSSSC;

public static void run(final SyncConfiguration syncConfiguration) {
EventQueue.invokeLater(new Runnable() {
Expand Down Expand Up @@ -111,9 +111,9 @@ public void stateChanged(ChangeEvent e) {
contentPane.add(proxyPasswordtextField);
proxyPasswordtextField.setColumns(10);

chckbxISSSC = new JCheckBox("Ignore self signed SSL certificates");
chckbxISSSC.setBounds(8, 170, 300, 23);
contentPane.add(chckbxISSSC);
chckbxTSSSC = new JCheckBox("Trust self signed SSL certificates");
chckbxTSSSC.setBounds(8, 170, 300, 23);
contentPane.add(chckbxTSSSC);

addWindowListener(new WindowAdapter() {
@Override
Expand All @@ -124,7 +124,7 @@ public void windowClosing(WindowEvent e) {
syncConfiguration.setProxyPort(proxyPorttextField.getText());
syncConfiguration.setProxyUsername(proxyLogintextField.getText());
syncConfiguration.setProxyPassword(proxyPasswordtextField.getText());
syncConfiguration.setIgnoreSelfSignedSSLCertificate(Boolean.toString(chckbxISSSC.isSelected()));
syncConfiguration.setTrustSelfSignedSSLCertificate(Boolean.toString(chckbxTSSSC.isSelected()));
}

@Override
Expand All @@ -135,7 +135,7 @@ public void windowOpened(WindowEvent e) {
proxyPorttextField.setText(syncConfiguration.getProxyPort() + "");
proxyLogintextField.setText(syncConfiguration.getProxyUsername());
proxyPasswordtextField.setText(syncConfiguration.getProxyPassword());
chckbxISSSC.setSelected(syncConfiguration.getIgnoreSelfSignedSSLCertificate());
chckbxTSSSC.setSelected(syncConfiguration.getTrustSelfSignedSSLCertificate());
}

});
Expand Down
2 changes: 1 addition & 1 deletion remotesync/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
<groupId>piwigo</groupId>
<artifactId>remotesync</artifactId>
<name>Piwigo Remote Sync</name>
<version>0.0.10</version>
<version>0.0.11</version>
<packaging>pom</packaging>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
Expand Down

0 comments on commit c06e97a

Please sign in to comment.