exchange

Base system with REST service to issue digital coins, run by the payment service provider
Log | Files | Refs | Submodules | README | LICENSE

0002-aml_staff.sql (1866B)


      1 --
      2 -- This file is part of TALER
      3 -- Copyright (C) 2014--2022 Taler Systems SA
      4 --
      5 -- TALER is free software; you can redistribute it and/or modify it under the
      6 -- terms of the GNU General Public License as published by the Free Software
      7 -- Foundation; either version 3, or (at your option) any later version.
      8 --
      9 -- TALER is distributed in the hope that it will be useful, but WITHOUT ANY
     10 -- WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
     11 -- A PARTICULAR PURPOSE.  See the GNU General Public License for more details.
     12 --
     13 -- You should have received a copy of the GNU General Public License along with
     14 -- TALER; see the file COPYING.  If not, see <http://www.gnu.org/licenses/>
     15 --
     16 
     17 
     18 CREATE TABLE aml_staff
     19   (aml_staff_uuid BIGINT GENERATED BY DEFAULT AS IDENTITY UNIQUE
     20   ,decider_pub BYTEA PRIMARY KEY CHECK (LENGTH(decider_pub)=32)
     21   ,master_sig BYTEA CHECK (LENGTH(master_sig)=64)
     22   ,decider_name TEXT NOT NULL
     23   ,is_active BOOLEAN NOT NULL
     24   ,read_only BOOLEAN NOT NULL
     25   ,last_change INT8 NOT NULL
     26   );
     27 COMMENT ON TABLE aml_staff
     28   IS 'Table with AML staff members the exchange uses or has used in the past. Entries never expire as we need to remember the last_change column indefinitely.';
     29 COMMENT ON COLUMN aml_staff.decider_pub
     30   IS 'Public key of the AML staff member.';
     31 COMMENT ON COLUMN aml_staff.master_sig
     32   IS 'The master public key signature on the AML staff member status, of type TALER_SIGNATURE_MASTER_AML_KEY.';
     33 COMMENT ON COLUMN aml_staff.decider_name
     34   IS 'Name of the staff member.';
     35 COMMENT ON COLUMN aml_staff.is_active
     36   IS 'true if we are currently supporting the use of this AML staff member.';
     37 COMMENT ON COLUMN aml_staff.is_active
     38   IS 'true if the member has read-only access.';
     39 COMMENT ON COLUMN aml_staff.last_change
     40   IS 'Latest time when active status changed. Used to detect replays of old messages.';