[openssl-commits] [tools] master update

Richard Levitte levitte at openssl.org
Mon May 7 07:37:58 UTC 2018


The branch master has been updated
       via  ba63b292f904eca32e6c707575af3bee1a238172 (commit)
      from  6c9eac0cab97aa1e4d98721ef3e68452f1839c5e (commit)


- Log -----------------------------------------------------------------
commit ba63b292f904eca32e6c707575af3bee1a238172
Author: Richard Levitte <levitte at openssl.org>
Date:   Mon May 7 09:31:51 2018 +0200

    QueryApp: rename bureau => omc, bump version

-----------------------------------------------------------------------

Summary of changes:
 QueryApp/MANIFEST                                     |  2 +-
 QueryApp/Makefile.PL                                  |  2 +-
 QueryApp/bin/query.psgi                               | 18 +++++++++---------
 QueryApp/lib/OpenSSL/Query/ClaDB.pm                   |  2 +-
 QueryApp/lib/OpenSSL/Query/PersonDB.pm                |  2 +-
 QueryApp/lib/OpenSSL/Query/Role/{Bureau.pm => OMC.pm} |  8 ++++----
 6 files changed, 17 insertions(+), 17 deletions(-)
 rename QueryApp/lib/OpenSSL/Query/Role/{Bureau.pm => OMC.pm} (81%)

diff --git a/QueryApp/MANIFEST b/QueryApp/MANIFEST
index 99f1b16..d9f0654 100644
--- a/QueryApp/MANIFEST
+++ b/QueryApp/MANIFEST
@@ -1,7 +1,7 @@
 bin/query.psgi
 lib/OpenSSL/Query/ClaDB.pm
 lib/OpenSSL/Query/DB.pm
-lib/OpenSSL/Query/Role/Bureau.pm
+lib/OpenSSL/Query/Role/OMC.pm
 lib/OpenSSL/Query/PersonDB.pm
 Makefile.PL
 MANIFEST
diff --git a/QueryApp/Makefile.PL b/QueryApp/Makefile.PL
index bb1dac9..56d57ca 100644
--- a/QueryApp/Makefile.PL
+++ b/QueryApp/Makefile.PL
@@ -4,7 +4,7 @@ use warnings;
 use inc::Module::Install;
 
 name     'QueryApp';
-version  '1.2';
+version  '2.0';
 abstract 'An OpenSSL query web app';
 author   q{Richard Levitte <levitte at openssl.org>};
 license  'apache';
diff --git a/QueryApp/bin/query.psgi b/QueryApp/bin/query.psgi
index ec9a994..523fb8f 100644
--- a/QueryApp/bin/query.psgi
+++ b/QueryApp/bin/query.psgi
@@ -55,7 +55,7 @@ use OpenSSL::Query::DB;
 use URI::Encode qw(uri_decode);
 
 set serializer => 'JSON';
-set bureau => '/var/cache/openssl/checkouts/bureau';
+set omc => '/var/cache/openssl/checkouts/omc';
 
 # Version 0 API.
 # Feel free to add new routes, but never to change them or remove them,
@@ -73,7 +73,7 @@ sub name_decode {
 }
 
 get '/People' => sub {
-  my $query = OpenSSL::Query->new(bureau => config->{bureau});
+  my $query = OpenSSL::Query->new(omc => config->{omc});
   my @response = $query->list_people();
 
   return [ @response ] if @response;
@@ -81,7 +81,7 @@ get '/People' => sub {
 };
 
 get '/Person/:name' => sub {
-  my $query = OpenSSL::Query->new(bureau => config->{bureau});
+  my $query = OpenSSL::Query->new(omc => config->{omc});
   my $name = name_decode(uri_decode(param('name')));
   my %response = $query->find_person($name);
 
@@ -90,7 +90,7 @@ get '/Person/:name' => sub {
 };
 
 get '/Person/:name/Membership' => sub {
-  my $query = OpenSSL::Query->new(bureau => config->{bureau}, REST => 0);
+  my $query = OpenSSL::Query->new(omc => config->{omc}, REST => 0);
   my $name = name_decode(uri_decode(param('name')));
   my %response = $query->find_person($name);
 
@@ -99,7 +99,7 @@ get '/Person/:name/Membership' => sub {
 };
 
 get '/Person/:name/IsMemberOf/:group' => sub {
-  my $query = OpenSSL::Query->new(bureau => config->{bureau}, REST => 0);
+  my $query = OpenSSL::Query->new(omc => config->{omc}, REST => 0);
   my $name = name_decode(uri_decode(param('name')));
   my $group = uri_decode(param('group'));
   my $response = $query->is_member_of($name, $group);
@@ -109,7 +109,7 @@ get '/Person/:name/IsMemberOf/:group' => sub {
 };
 
 get '/Person/:name/ValueOfTag/:tag' => sub {
-  my $query = OpenSSL::Query->new(bureau => config->{bureau}, REST => 0);
+  my $query = OpenSSL::Query->new(omc => config->{omc}, REST => 0);
   my $name = name_decode(uri_decode(param('name')));
   my $tag = uri_decode(param('tag'));
   my $response = $query->find_person_tag($name, $tag);
@@ -119,7 +119,7 @@ get '/Person/:name/ValueOfTag/:tag' => sub {
 };
 
 get '/Person/:name/HasCLA' => sub {
-  my $query = OpenSSL::Query->new(bureau => config->{bureau}, REST => 0);
+  my $query = OpenSSL::Query->new(omc => config->{omc}, REST => 0);
   my $name = name_decode(uri_decode(param('name')));
   my %person = $query->find_person($name);
   my @response = ();
@@ -134,7 +134,7 @@ get '/Person/:name/HasCLA' => sub {
 };
 
 get '/Group/:group/Members' => sub {
-  my $query = OpenSSL::Query->new(bureau => config->{bureau}, REST => 0);
+  my $query = OpenSSL::Query->new(omc => config->{omc}, REST => 0);
   my $group = uri_decode(param('group'));
   my @response = $query->members_of($group);
 
@@ -143,7 +143,7 @@ get '/Group/:group/Members' => sub {
 };
 
 get '/HasCLA/:id' => sub {
-  my $query = OpenSSL::Query->new(bureau => config->{bureau}, REST => 0);
+  my $query = OpenSSL::Query->new(omc => config->{omc}, REST => 0);
   my $id = uri_decode(param('id'));
   if ($id =~ m|^\S+\@\S+$|) {
     my $response = $query->has_cla($id);
diff --git a/QueryApp/lib/OpenSSL/Query/ClaDB.pm b/QueryApp/lib/OpenSSL/Query/ClaDB.pm
index 406b445..bcd6daf 100644
--- a/QueryApp/lib/OpenSSL/Query/ClaDB.pm
+++ b/QueryApp/lib/OpenSSL/Query/ClaDB.pm
@@ -14,7 +14,7 @@ use Carp;
 use Moo;
 use OpenSSL::Query qw(-register-cla OpenSSL::Query::ClaDB -priority 0);
 
-with q(OpenSSL::Query::Role::Bureau);
+with q(OpenSSL::Query::Role::OMC);
 
 has clafile => ( is => 'ro', default => 'cladb.txt' );
 has _cladb => ( is => 'lazy', builder => 1 );
diff --git a/QueryApp/lib/OpenSSL/Query/PersonDB.pm b/QueryApp/lib/OpenSSL/Query/PersonDB.pm
index ab5507b..c26164b 100644
--- a/QueryApp/lib/OpenSSL/Query/PersonDB.pm
+++ b/QueryApp/lib/OpenSSL/Query/PersonDB.pm
@@ -16,7 +16,7 @@ use Clone qw(clone);
 use Moo;
 use OpenSSL::Query qw(-register-person OpenSSL::Query::PersonDB -priority 0);
 
-with q(OpenSSL::Query::Role::Bureau);
+with q(OpenSSL::Query::Role::OMC);
 
 has personfile => ( is => 'ro', default => 'persondb.yaml' );
 has _persondb => ( is => 'lazy', builder => 1 );
diff --git a/QueryApp/lib/OpenSSL/Query/Role/Bureau.pm b/QueryApp/lib/OpenSSL/Query/Role/OMC.pm
similarity index 81%
rename from QueryApp/lib/OpenSSL/Query/Role/Bureau.pm
rename to QueryApp/lib/OpenSSL/Query/Role/OMC.pm
index f4771b5..9410084 100644
--- a/QueryApp/lib/OpenSSL/Query/Role/Bureau.pm
+++ b/QueryApp/lib/OpenSSL/Query/Role/OMC.pm
@@ -10,22 +10,22 @@
 use strict;
 use warnings;
 
-package OpenSSL::Query::Role::Bureau;
+package OpenSSL::Query::Role::OMC;
 
 use Carp;
 use File::Spec::Functions;
 use Moo::Role;
 
-has bureau => ( is => 'ro' );
+has omc => ( is => 'ro' );
 
 sub _find_file {
   my $self = shift;
   my $filename = shift;
   my $envvar = shift;
 
-  my $bureau = $ENV{BUREAU} // $self->bureau;
+  my $omc = $ENV{OMC} // $ENV{BUREAU} // $self->omc;
   my @paths = ( $ENV{$envvar} // (),
-		$bureau ? catfile($bureau, $filename) : (),
+		$omc ? catfile($omc, $filename) : (),
 		catfile('.', $filename) );
   foreach (@paths) {
     return $_ if -r $_;


More information about the openssl-commits mailing list