Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

What about policies to be used by plugins? #14

Closed
juniorz opened this issue May 8, 2017 · 5 comments
Closed

What about policies to be used by plugins? #14

juniorz opened this issue May 8, 2017 · 5 comments
Assignees
Labels
architecture importance medium An issue that is medium level importance. It's good to have but not 100% necessary. pidgin plugin

Comments

@juniorz
Copy link
Member

juniorz commented May 8, 2017

Should we implement the policies in the plugin?

@juniorz juniorz added this to the Working prototype milestone May 8, 2017
@rosatolen rosatolen changed the title What about policies? What about policies for the pidgin plugin? Jul 7, 2017
@claucece claucece self-assigned this Dec 15, 2017
claucece added a commit that referenced this issue Dec 19, 2017
claucece added a commit that referenced this issue Dec 20, 2017
@claucece claucece removed their assignment Apr 3, 2018
@claucece claucece removed this from the Working prototype milestone Apr 10, 2018
@claucece claucece changed the title What about policies for the pidgin plugin? What about policies to be used by plugins? Jun 26, 2018
@claucece claucece added importance medium An issue that is medium level importance. It's good to have but not 100% necessary. and removed waiting labels Jun 26, 2018
@claucece
Copy link
Member

claucece commented Aug 9, 2018

We decided to go for (from a specification perspective):

"""
ALLOW_V3
  Allow version 3 of the OTR protocol to be used.
ALLOW_V4
  Allow version 4 of the OTR protocol to be used.
REQUIRE_ENCRYPTION
  Refuse to send unencrypted messages.
SEND_WHITESPACE_TAG
  Advertise your support of OTR using the whitespace tag.
WHITESPACE_START_DAKE
  Start the OTR DAKE when you receive a whitespace tag.
ERROR_START_DAKE
  Start the OTR DAKE when you receive an OTR Error Message.
REQUIRE_INTERACTIVE
  Refuse to start with a non-interactive DAKE.
IDENTITY_START_DAKE
  Start OTR interactive DAKE with the sending of the Identity Message only.
TRY_DAKEZ_WHEN_OFFLINE
  Try to start an offline conversation with DAKEZ.
REQUIRE_AUTHENTICATED
  Always start an OTR conversation with authenticated parties only. 

From the library to plugin perspective:

#define OTRL_POLICY_NEVER                       0x00
#define OTRL_POLICY_OPPORTUNISTIC \
           ( OTRL_POLICY_ALLOW_V3 | \
            OTRL_POLICY_ALLOW_V4 | \
            OTRL_POLICY_SEND_WHITESPACE_TAG | \
            OTRL_POLICY_WHITESPACE_START_AKE | \
            OTRL_POLICY_ERROR_START_AKE )
#define OTRL_POLICY_MANUAL \
            ( OTRL_POLICY_ALLOW_V3 | \
             OTRL_POLICY_ALLOW_V4)
#define OTRL_POLICY_ALWAYS \
            ( OTRL_POLICY_ALLOW_V3 | \
             OTRL_POLICY_ALLOW_V4 | \
             OTRL_POLICY_REQUIRE_ENCRYPTION | \
             OTRL_POLICY_WHITESPACE_START_AKE | \
             OTRL_POLICY_ERROR_START_AKE )
#define OTRL_POLICY_DEFAULT OTRL_POLICY_OPPORTUNISTIC

We can further include

We can have:

OTRL_POLICY_HIGHEST_SEC 
 	    OTRL_POLICY_ALLOW_V3 | \
 	    OTRL_POLICY_ALLOW_V4 | \
 	    OTRL_POLICY_SEND_WHITESPACE_TAG | \
 	    OTRL_POLICY_WHITESPACE_START_AKE | \
 	    OTRL_POLICY_ERROR_START_AKE 
	    REQUIRE_AUTHENTICATED | \
	    REQUIRE_INTERACTIVE \
	    IDENTITY_START_DAKE \
	    )

OTRL_POLICY_OTRV4_FULL 
 	    OTRL_POLICY_ALLOW_V4 | \
 	    OTRL_POLICY_SEND_WHITESPACE_TAG | \
 	    OTRL_POLICY_WHITESPACE_START_AKE | \
 	    OTRL_POLICY_ERROR_START_AKE 
	    )

@olabini
Copy link
Contributor

olabini commented Aug 25, 2018

Most of the policies should be implemented in libotr-ng - as discussed in the email thread.

@claucece
Copy link
Member

@olabini yes! already had an issue for that :)

@olabini
Copy link
Contributor

olabini commented Sep 21, 2018

OK, this story has been broken up into several smaller stories:
#145, #146, #147, #148, #149, #150, #151, #152, #153, #154 and #155.

@olabini olabini closed this as completed Sep 21, 2018
@claucece
Copy link
Member

Thanks! @olabini

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
architecture importance medium An issue that is medium level importance. It's good to have but not 100% necessary. pidgin plugin
Projects
None yet
Development

No branches or pull requests

3 participants