forked from openhab/openhab-addons
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ihc] Support for TLSv1.2 (openhab#10856)
* [ihc] Support for TLSv1.2 So far IHC controller have supported only TLSv1. As TLSv1 is already deprecated and upcoming IHC controller FW version will introduce support for TLSv1.2. This change introduce TLSv1.2 support for the binding. TLS version is selectable to be backward compatible for older controller versions. Communication error handling is also improved e.g. because of wrong password or if Java environment doesn't support required TLS version. When fatal communication error occurs, binding will not hammer controller with retries as it need user actions. Signed-off-by: Pauli Anttila <pauli.anttila@gmail.com> * [ihc] Introduced auto mode and other improvements Signed-off-by: Pauli Anttila <pauli.anttila@gmail.com> * [ihc] introduced default constant Signed-off-by: Pauli Anttila <pauli.anttila@gmail.com> Signed-off-by: Luca Calcaterra <calcaterra.luca@gmail.com>
- Loading branch information
1 parent
55fab95
commit 37759cf
Showing
9 changed files
with
207 additions
and
73 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
38 changes: 38 additions & 0 deletions
38
...ng.ihc/src/main/java/org/openhab/binding/ihc/internal/ws/exeptions/IhcFatalExecption.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
/** | ||
* Copyright (c) 2010-2021 Contributors to the openHAB project | ||
* | ||
* See the NOTICE file(s) distributed with this work for additional | ||
* information. | ||
* | ||
* This program and the accompanying materials are made available under the | ||
* terms of the Eclipse Public License 2.0 which is available at | ||
* http://www.eclipse.org/legal/epl-2.0 | ||
* | ||
* SPDX-License-Identifier: EPL-2.0 | ||
*/ | ||
package org.openhab.binding.ihc.internal.ws.exeptions; | ||
|
||
/** | ||
* Exception for handling fatal communication errors to controller. | ||
* | ||
* @author Pauli Anttila - Initial contribution | ||
*/ | ||
public class IhcFatalExecption extends IhcExecption { | ||
|
||
private static final long serialVersionUID = -8107948791816894352L; | ||
|
||
public IhcFatalExecption() { | ||
} | ||
|
||
public IhcFatalExecption(String message) { | ||
super(message); | ||
} | ||
|
||
public IhcFatalExecption(String message, Throwable cause) { | ||
super(message, cause); | ||
} | ||
|
||
public IhcFatalExecption(Throwable cause) { | ||
super(cause); | ||
} | ||
} |
38 changes: 38 additions & 0 deletions
38
...ding.ihc/src/main/java/org/openhab/binding/ihc/internal/ws/exeptions/IhcTlsExecption.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
/** | ||
* Copyright (c) 2010-2021 Contributors to the openHAB project | ||
* | ||
* See the NOTICE file(s) distributed with this work for additional | ||
* information. | ||
* | ||
* This program and the accompanying materials are made available under the | ||
* terms of the Eclipse Public License 2.0 which is available at | ||
* http://www.eclipse.org/legal/epl-2.0 | ||
* | ||
* SPDX-License-Identifier: EPL-2.0 | ||
*/ | ||
package org.openhab.binding.ihc.internal.ws.exeptions; | ||
|
||
/** | ||
* Exception for handling TLS communication errors to controller. | ||
* | ||
* @author Pauli Anttila - Initial contribution | ||
*/ | ||
public class IhcTlsExecption extends IhcFatalExecption { | ||
|
||
private static final long serialVersionUID = -1366186910684967044L; | ||
|
||
public IhcTlsExecption() { | ||
} | ||
|
||
public IhcTlsExecption(String message) { | ||
super(message); | ||
} | ||
|
||
public IhcTlsExecption(String message, Throwable cause) { | ||
super(message, cause); | ||
} | ||
|
||
public IhcTlsExecption(Throwable cause) { | ||
super(cause); | ||
} | ||
} |
Oops, something went wrong.