Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
X
xabber-android
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Administrator
xabber-android
Commits
5103ab07
Commit
5103ab07
authored
Apr 01, 2015
by
Grigory Fedorov
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'develop' into feature/new_contact_list_design
parents
63e62798
d1b64345
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
9 deletions
+8
-9
otr4j
app/otr4j
+1
-1
OTRManager.java
...ava/com/xabber/android/data/extension/otr/OTRManager.java
+7
-8
No files found.
otr4j
@
284a850b
Subproject commit
ab1d28e8641238bcfd0ba11c0477da1d99f38a11
Subproject commit
284a850bbed4b678375f84dfde06118986954678
app/src/main/java/com/xabber/android/data/extension/otr/OTRManager.java
View file @
5103ab07
...
@@ -48,8 +48,7 @@ import net.java.otr4j.OtrEngineHost;
...
@@ -48,8 +48,7 @@ import net.java.otr4j.OtrEngineHost;
import
net.java.otr4j.OtrEngineListener
;
import
net.java.otr4j.OtrEngineListener
;
import
net.java.otr4j.OtrException
;
import
net.java.otr4j.OtrException
;
import
net.java.otr4j.OtrPolicy
;
import
net.java.otr4j.OtrPolicy
;
import
net.java.otr4j.OtrPolicyImpl
;
import
net.java.otr4j.crypto.OtrCryptoEngine
;
import
net.java.otr4j.crypto.OtrCryptoEngineImpl
;
import
net.java.otr4j.crypto.OtrCryptoException
;
import
net.java.otr4j.crypto.OtrCryptoException
;
import
net.java.otr4j.io.SerializationUtils
;
import
net.java.otr4j.io.SerializationUtils
;
import
net.java.otr4j.session.InstanceTag
;
import
net.java.otr4j.session.InstanceTag
;
...
@@ -82,13 +81,13 @@ public class OTRManager implements OtrEngineHost, OtrEngineListener,
...
@@ -82,13 +81,13 @@ public class OTRManager implements OtrEngineHost, OtrEngineListener,
static
{
static
{
POLICIES
=
new
HashMap
<
SettingsManager
.
SecurityOtrMode
,
OtrPolicy
>();
POLICIES
=
new
HashMap
<
SettingsManager
.
SecurityOtrMode
,
OtrPolicy
>();
POLICIES
.
put
(
SecurityOtrMode
.
disabled
,
new
OtrPolicy
Impl
(
POLICIES
.
put
(
SecurityOtrMode
.
disabled
,
new
OtrPolicy
(
OtrPolicy
.
NEVER
));
OtrPolicy
.
NEVER
));
POLICIES
.
put
(
SecurityOtrMode
.
manual
,
new
OtrPolicy
Impl
(
POLICIES
.
put
(
SecurityOtrMode
.
manual
,
new
OtrPolicy
(
OtrPolicy
.
OTRL_POLICY_MANUAL
&
~
OtrPolicy
.
ALLOW_V1
));
OtrPolicy
.
OTRL_POLICY_MANUAL
&
~
OtrPolicy
.
ALLOW_V1
));
POLICIES
.
put
(
SecurityOtrMode
.
auto
,
new
OtrPolicy
Impl
(
POLICIES
.
put
(
SecurityOtrMode
.
auto
,
new
OtrPolicy
(
OtrPolicy
.
OPPORTUNISTIC
&
~
OtrPolicy
.
ALLOW_V1
));
OtrPolicy
.
OPPORTUNISTIC
&
~
OtrPolicy
.
ALLOW_V1
));
POLICIES
.
put
(
SecurityOtrMode
.
required
,
new
OtrPolicy
Impl
(
POLICIES
.
put
(
SecurityOtrMode
.
required
,
new
OtrPolicy
(
OtrPolicy
.
OTRL_POLICY_ALWAYS
&
~
OtrPolicy
.
ALLOW_V1
));
OtrPolicy
.
OTRL_POLICY_ALWAYS
&
~
OtrPolicy
.
ALLOW_V1
));
}
}
...
@@ -366,7 +365,7 @@ public class OTRManager implements OtrEngineHost, OtrEngineListener,
...
@@ -366,7 +365,7 @@ public class OTRManager implements OtrEngineHost, OtrEngineListener,
PublicKey
remotePublicKey
=
session
.
getRemotePublicKey
();
PublicKey
remotePublicKey
=
session
.
getRemotePublicKey
();
String
value
;
String
value
;
try
{
try
{
value
=
new
OtrCryptoEngine
Impl
()
value
=
new
OtrCryptoEngine
()
.
getFingerprint
(
remotePublicKey
);
.
getFingerprint
(
remotePublicKey
);
}
catch
(
OtrCryptoException
e
)
{
}
catch
(
OtrCryptoException
e
)
{
LogManager
.
exception
(
this
,
e
);
LogManager
.
exception
(
this
,
e
);
...
@@ -543,7 +542,7 @@ public class OTRManager implements OtrEngineHost, OtrEngineListener,
...
@@ -543,7 +542,7 @@ public class OTRManager implements OtrEngineHost, OtrEngineListener,
public
String
getLocalFingerprint
(
String
account
)
{
public
String
getLocalFingerprint
(
String
account
)
{
try
{
try
{
return
new
OtrCryptoEngine
Impl
().
getFingerprint
(
getLocalKeyPair
(
return
new
OtrCryptoEngine
().
getFingerprint
(
getLocalKeyPair
(
account
).
getPublic
());
account
).
getPublic
());
}
catch
(
OtrCryptoException
e
)
{
}
catch
(
OtrCryptoException
e
)
{
LogManager
.
exception
(
this
,
e
);
LogManager
.
exception
(
this
,
e
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment