kyc risk and AML & Compliance Checks automate on client creation
Fineract Cargo & Unit- & Integration tests - MariaDB / test (test-core-3) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - MariaDB / test (test-core-4) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - MariaDB / test (test-core-5) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - MySQL / test (test-core-1) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - MySQL / test (test-core-2) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - MySQL / test (test-core-3) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - MySQL / test (test-core-4) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - MySQL / test (test-core-5) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - PostgreSQL / test (test-core-1) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - PostgreSQL / test (test-core-2) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - PostgreSQL / test (test-core-3) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - PostgreSQL / test (test-core-4) (push) Canceled after 0s
Fineract E2E Tests / E2E Tests (Shard 8 of 10) (push) Canceled after 0s
Fineract E2E Tests / E2E Tests (Shard 9 of 10) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - MariaDB / test (test-core-1) (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - MariaDB / test (test-core-2) (push) Canceled after 0s
Fineract Docker Builds / build (false, docker-compose-postgresql.yml, postgresql) (push) Canceled after 0s
Fineract Docker Builds / build (true, docker-compose.yml, mariadb) (push) Canceled after 0s
Fineract Documentation build / build (push) Canceled after 0s
Fineract E2E Tests / E2E Tests (Shard 1 of 10) (push) Canceled after 0s
Fineract E2E Tests / E2E Tests (Shard 10 of 10) (push) Canceled after 0s
Fineract E2E Tests / E2E Tests (Shard 2 of 10) (push) Canceled after 0s
Fineract E2E Tests / E2E Tests (Shard 3 of 10) (push) Canceled after 0s
Fineract E2E Tests / E2E Tests (Shard 4 of 10) (push) Canceled after 0s
Fineract E2E Tests / E2E Tests (Shard 5 of 10) (push) Canceled after 0s
Fineract E2E Tests / E2E Tests (Shard 6 of 10) (push) Canceled after 0s
Fineract E2E Tests / E2E Tests (Shard 7 of 10) (push) Canceled after 0s
Fineract Liquibase Only mode - PostgreSQL / test (push) Canceled after 0s
Fineract Messaging Smoke Tests / Smoke Test with ActiveMQ (push) Canceled after 0s
Fineract Cargo & Unit- & Integration tests - PostgreSQL / test (test-core-5) (push) Canceled after 0s
Fineract Build & Cucumber tests (without E2E tests) / verify (main, build-core) (push) Canceled after 0s
Fineract Build & Cucumber tests (without E2E tests) / verify (main, cucumber) (push) Canceled after 0s
Fineract Build & Cucumber tests (without E2E tests) / verify (progressive-loan, build-progressive-loan) (push) Canceled after 0s
Fineract Messaging Smoke Tests / Smoke Test with Kafka (push) Canceled after 0s

This commit is contained in:
2026-07-31 11:02:31 +05:30
parent b1cfa996b4
commit 2022dc5241
80 changed files with 4595 additions and 3 deletions
@@ -483,4 +483,10 @@
<include file="parts/0362_add_share_account_edit_approval_permissions.xml" relativeToChangelogFile="true"/>
<include file="parts/0421_add_master_salutation_value.xml" relativeToChangelogFile="true"/>
<include file="parts/0428_add_client_risk_rules.xml" relativeToChangelogFile="true"/>
<include file="parts/0429_add_aml_fields_to_risk_rules.xml" relativeToChangelogFile="true"/>
<include file="parts/0430_seed_aml_compliance_rules.xml" relativeToChangelogFile="true"/>
<include file="parts/0433_create_aml_transaction_monitoring_tables.xml" relativeToChangelogFile="true"/>
<include file="parts/0434_seed_aml_transaction_rules.xml" relativeToChangelogFile="true"/>
<include file="parts/0435_add_aml_officer_and_principal_officer_roles.xml" relativeToChangelogFile="true"/>
<include file="parts/0436_fix_missing_client_risk_rule_columns.xml" relativeToChangelogFile="true"/>
</databaseChangeLog>
@@ -0,0 +1,39 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-4.13.xsd">
<changeSet author="fineract" id="0429-1">
<preConditions onFail="MARK_RAN">
<not><columnExists tableName="m_client_risk_rule" columnName="aml_check_status"/></not>
</preConditions>
<addColumn tableName="m_client_risk_rule">
<column name="aml_check_status" type="VARCHAR(20)"/>
<column name="banned_entity_match" type="VARCHAR(10)"/>
<column name="willful_defaulter" type="VARCHAR(10)"/>
<column name="ecgc_sal_flag" type="VARCHAR(10)"/>
<column name="dormant_flag" type="VARCHAR(20)"/>
</addColumn>
</changeSet>
<changeSet author="fineract" id="0429-2">
<modifyDataType tableName="m_client_risk_rule" columnName="rule_name" newDataType="VARCHAR(500)"/>
<modifyDataType tableName="m_client_risk_rule" columnName="reason" newDataType="VARCHAR(500)"/>
</changeSet>
</databaseChangeLog>
@@ -0,0 +1,255 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-4.13.xsd">
<changeSet author="fineract" id="0430-1">
<preConditions onFail="MARK_RAN">
<sqlCheck expectedResult="0">SELECT COUNT(*) FROM m_client_risk_rule WHERE order_position = 1 AND rule_name LIKE 'Maintaining%'</sqlCheck>
</preConditions>
<sql>
INSERT INTO m_client_risk_rule (rule_name, legal_form_id, occupation_category_cv_id, occupation_cv_id, min_monthly_income, min_annual_income, min_annual_turnover, risk_category, reason, order_position, aml_check_status, banned_entity_match, willful_defaulter, ecgc_sal_flag, dormant_flag)
VALUES
('Maintaining a low or overdrawn balance with high activity', null, null, null, null, null, null, 3, 'Maintaining a low or overdrawn balance with high activity', 1, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Multiple deposit of Mcs/DDs. etc followed by immediate withdrawal', null, null, null, null, null, null, 3, 'Multiple deposit of Mcs/DDs. etc followed by immediate withdrawal', 2, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Same funds being moved repeatedly among several accounts', null, null, null, null, null, null, 3, 'Same funds being moved repeatedly among several accounts', 3, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Sudden surge in activity level', null, null, null, null, null, null, 3, 'Sudden surge in activity level', 4, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Multiple accounts under the same name', null, null, null, null, null, null, 2, 'Multiple accounts under the same name', 5, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Large cash transaction', null, null, null, null, null, null, 3, 'Large cash transaction', 6, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('An account of a customer who does not reside/ have office near to the branch even though there are bank branches near his office/residence', null, null, null, null, null, null, 2, 'Customer does not reside near the branch', 7, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Depositing cash by means of numerous credit slip such that the amount of each deposit is not substantial but the total of which is substantial', null, null, null, null, null, null, 3, 'Deposits total is substantial', 8, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Unexplained activity in dormant account', null, null, null, null, null, null, 3, 'Unexplained activity in dormant account', 9, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Substantial cash withdrawals in accounts of charitable organization', null, null, null, null, null, null, 3, 'Substantial cash withdrawals in accounts of charitable organization', 10, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Monitoring accounts of PEP(politically exposed person)', null, null, null, null, null, null, 3, 'Monitoring accounts of PEP (politically exposed person)', 11, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Monitoring RTGS Transactions', null, null, null, null, null, null, 2, 'Monitoring RTGS Transactions', 12, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Monitoring accounts of Jewellers', null, null, null, null, null, null, 3, 'Monitoring accounts of Jewellers', 13, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('New account Large transaction', null, null, null, null, null, null, 2, 'New account Large transaction', 14, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Non Home Branch Transaction', null, null, null, null, null, null, 2, 'Non Home Branch Transaction', 15, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Monitoring accounts of Staff', null, null, null, null, null, null, 2, 'Monitoring accounts of Staff', 16, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High Net worth', null, null, null, null, null, null, 2, 'High Net worth', 17, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customers with common phone numbers,mobile numbers', null, null, null, null, null, null, 2, 'Customers with common phone numbers / mobile numbers', 18, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High Value Transactions without PAN ID', null, null, null, null, null, null, 3, 'High Value Transactions without PAN ID', 19, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customers joint holder in multiple accounts', null, null, null, null, null, null, 2, 'Customers joint holder in multiple accounts', 20, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Structuring of deposits through multiple branches', null, null, null, null, null, null, 3, 'Structuring of deposits through multiple branches', 21, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Monitoring NEFT Transactions', null, null, null, null, null, null, 2, 'Monitoring NEFT Transactions', 22, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Large cash transaction(Debit)', null, null, null, null, null, null, 3, 'Large cash transaction (Debit)', 23, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Rapid Movement in accounts', null, null, null, null, null, null, 3, 'Rapid Movement in accounts', 24, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Risk Categorization', null, null, null, null, null, null, 2, 'Risk Categorization', 25, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High Value Cash transaction inconsistent with Profile', null, null, null, null, null, null, 3, 'High Value Cash transaction inconsistent with Profile', 26, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High Cash Activity inconsistent with Profile', null, null, null, null, null, null, 3, 'High Cash Activity inconsistent with Profile', 27, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Splitting of Cash deposits just below INR 10, 00, 000 in multiple accounts in a month', null, null, null, null, null, null, 3, 'Splitting of Cash deposits below INR 10 Lakhs', 28, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Splitting of cash deposits just below INR 50000', null, null, null, null, null, null, 3, 'Splitting of cash deposits below INR 50K', 29, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Frequent low cash deposits', null, null, null, null, null, null, 2, 'Frequent low cash deposits', 30, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Frequent low cash withdrawals', null, null, null, null, null, null, 2, 'Frequent low cash withdrawals', 31, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Many to One Fund Transfer', null, null, null, null, null, null, 3, 'Many to One Fund Transfer', 32, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('One to Many fund transfer', null, null, null, null, null, null, 3, 'One to Many fund transfer', 33, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Multiple customers working together', null, null, null, null, null, null, 3, 'Multiple customers working together', 34, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Repeated small cash deposits followed by immediate ATM withdrawals in different location', null, null, null, null, null, null, 3, 'Repeated small deposits followed by ATM withdrawals', 35, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Repeated small value inward transfer from unrelated parties followed by immediate ATM withdrawals', null, null, null, null, null, null, 3, 'Inward transfer followed by ATM withdrawals', 36, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Repeated small value inward remittance from unrelated parties followed by ATM withdrawals', null, null, null, null, null, null, 3, 'Inward remittance followed by ATM withdrawals', 37, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Repayment of loan in cash', null, null, null, null, null, null, 2, 'Repayment of loan in cash', 38, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Premature closure of large FDR through PO/DD', null, null, null, null, null, null, 2, 'Premature closure of large FDR through PO/DD', 39, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High number of cheque leaves', null, null, null, null, null, null, 2, 'High number of cheque leaves', 40, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High value inward remittance', null, null, null, null, null, null, 3, 'High value inward remittance', 41, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Inward remittance in a new account', null, null, null, null, null, null, 3, 'Inward remittance in a new account', 42, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Threshold Limit in Credit entry', null, null, null, null, null, null, 2, 'Threshold Limit in Credit entry', 43, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Sudden Increase in Value of Transactions in a Month for the Client', null, null, null, null, null, null, 3, 'Sudden Increase in Value of Transactions in a Month for the Client', 44, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Number of Transactions in newly opened Accounts, monthly', null, null, null, null, null, null, 2, 'Number of Transactions in newly opened Accounts, monthly', 45, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Frequent Locker Operations (Monthly)', null, null, null, null, null, null, 2, 'Frequent Locker Operations (Monthly)', 46, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High Value Transactions in current account', null, null, null, null, null, null, 3, 'High Value Transactions in current account', 47, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Monitor accounts of parties'' occupation related to Real Estate', null, null, null, null, null, null, 3, 'Monitor accounts of parties'' occupation related to Real Estate', 48, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Large repetitive card usage at the same merchant', null, null, null, null, null, null, 2, 'Large repetitive card usage at the same merchant', 49, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Sudden High Value Transaction for the Client(Monthly)', null, null, null, null, null, null, 3, 'Sudden High Value Transaction for the Client (Monthly)', 50, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('One to Many Fund Transfer (Monthly)', null, null, null, null, null, null, 3, 'One to Many Fund Transfer (Monthly)', 51, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Many to One Fund Transfer (Monthly)', null, null, null, null, null, null, 3, 'Many to One Fund Transfer (Monthly)', 52, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Inward Remittance Inconsistent with Client Profile (Monthly)', null, null, null, null, null, null, 3, 'Inward Remittance Inconsistent with Client Profile (Monthly)', 53, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High Value Non- Cash Deposits in a day', null, null, null, null, null, null, 3, 'High Value Non-Cash Deposits in a day', 55, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High Value non- Cash Withdrawal in a day', null, null, null, null, null, null, 3, 'High Value non-Cash Withdrawal in a day', 56, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High Value Cash Deposits in a month', null, null, null, null, null, null, 3, 'High Value Cash Deposits in a month', 57, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High Value Cash Withdrawals in a month', null, null, null, null, null, null, 3, 'High Value Cash Withdrawals in a month', 58, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High Value non-cash Deposits in a month', null, null, null, null, null, null, 3, 'High Value non-cash Deposits in a month', 59, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High value non-cash withdrawals in a month', null, null, null, null, null, null, 3, 'High value non-cash withdrawals in a month', 60, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Sudden high value transaction for the client', null, null, null, null, null, null, 3, 'Sudden high value transaction for the client', 61, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Sudden increase in value of transactions in a month for the client', null, null, null, null, null, null, 3, 'Sudden increase in value of transactions in a month for the client', 62, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Sudden increase in number of transactions in a month for the client', null, null, null, null, null, null, 2, 'Sudden increase in number of transactions in a month for the client', 63, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High Value transactions in a new Account', null, null, null, null, null, null, 3, 'High Value transactions in a new Account', 64, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Frequent cash deposits just below INR 10,00,000', null, null, null, null, null, null, 3, 'Frequent cash deposits below INR 10 Lakhs', 65, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High Value transactions by high risk customers', null, null, null, null, null, null, 3, 'High Value transactions by high risk customers', 66, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High activity in a new account', null, null, null, null, null, null, 3, 'High activity in a new account', 67, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High value Cash transactions in accounts without PAN', null, null, null, null, null, null, 3, 'High value Cash transactions in accounts without PAN', 68, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('high value non cash transactions in accounts without PAN', null, null, null, null, null, null, 3, 'high value non cash transactions in accounts without PAN', 69, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Repeated small value transfers to a single Indian party', null, null, null, null, null, null, 3, 'Repeated small value transfers to a single Indian party', 70, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Repeated small value transfers to multiple parties followed by immediate cash/non-cash withdrawals (through ATMs or other modes)', null, null, null, null, null, null, 3, 'Repeated small value transfers with immediate withdrawals', 71, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Repayment of loan in cash greater than INR [X] in [Y] months', null, null, null, null, null, null, 2, 'Repayment of loan in cash greater than threshold', 72, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Repayment of loan in cash', null, null, null, null, null, null, 2, 'Repayment of loan in cash', 73, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Sudden increase in cash deposits of customers', null, null, null, null, null, null, 3, 'Sudden increase in cash deposits of customers', 74, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Sudden increase in cash withdrawals of customers', null, null, null, null, null, null, 3, 'Sudden increase in cash withdrawals of customers', 75, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High value transactions in accounts opened and closed in a short duration', null, null, null, null, null, null, 3, 'High value transactions in accounts opened and closed in short duration', 76, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Unusually high activity in Current Account(CA)', null, null, null, null, null, null, 3, 'Unusually high activity in Current Account (CA)', 77, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('NPOs or charities receiving funds from India or abroad, and transferring the same to a number of domestic and foreign beneficiaries', null, null, null, null, null, null, 3, 'NPOs/Charities transferring funds to domestic/foreign beneficiaries', 78, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High value cash deposits in a day', null, null, null, null, null, null, 3, 'High value cash deposits in a day', 79, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High value cash withdrawals in a day', null, null, null, null, null, null, 3, 'High value cash withdrawals in a day', 80, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High value transactions in new accounts followed by period of inactivity', null, null, null, null, null, null, 3, 'High value transactions followed by inactivity', 81, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Frequent low cash withdrawals', null, null, null, null, null, null, 2, 'Frequent low cash withdrawals', 82, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('GST Refund Fraud', null, null, null, null, null, null, 3, 'GST Refund Fraud detected', 83, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Additional RFIs Rule - 91', null, null, null, null, null, null, 2, 'Additional RFIs Rule - 91', 91, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Additional RFIs Rule - 92', null, null, null, null, null, null, 2, 'Additional RFIs Rule - 92', 92, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Additional RFIs Rule - 93', null, null, null, null, null, null, 2, 'Additional RFIs Rule - 93', 93, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Additional RFIs Rule - 94', null, null, null, null, null, null, 2, 'Additional RFIs Rule - 94', 94, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Amounts of money transfer carried out by natural persons and legal entities are in multiples of 100/1,000 /10,000/100,000 USD/EUR/National currency', null, null, null, null, null, null, 3, 'Money transfer in round multiples of currency', 101, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Cash deposits followed by immediate outward remittance transactions', null, null, null, null, null, null, 3, 'Cash deposits followed by immediate outward remittance', 102, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Cross border transaction involving a country with high TF risk', null, null, null, null, null, null, 3, 'Cross border transaction involving high TF risk country', 103, 'FLAGGED', 'YES', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - High value cross border transactions with a country or location with high ML risk/ tax havens', null, null, null, null, null, null, 3, 'High value cross border transaction involving high ML risk country', 104, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - High value foreign inward remittance', null, null, null, null, null, null, 3, 'High value foreign inward remittance', 105, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - High value outward remittances in accounts', null, null, null, null, null, null, 3, 'High value outward remittances in accounts', 106, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Inward foreign remittance in a new account', null, null, null, null, null, null, 3, 'Inward foreign remittance in a new account', 107, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Inward foreign remittance inconsistent with client profile', null, null, null, null, null, null, 3, 'Inward foreign remittance inconsistent with client profile', 108, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Inward remittance followed by immediate withdrawal/transfer to other accounts', null, null, null, null, null, null, 3, 'Inward remittance followed by immediate transfer', 109, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Inward remittance of same value from same remitter', null, null, null, null, null, null, 3, 'Inward remittance of same value from same remitter', 110, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Multiple cash deposits in one country followed by immediate ATM withdrawal in another country', null, null, null, null, null, null, 3, 'Multiple cash deposits followed by ATM withdrawal in another country', 111, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Non-cash deposits followed by immediate outward remittance transactions', null, null, null, null, null, null, 3, 'Non-cash deposits followed by immediate outward remittance', 112, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Outward foreign remittances in newly opened accounts', null, null, null, null, null, null, 3, 'Outward foreign remittances in newly opened accounts', 113, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Reg. NGOs - Prior Reference Category', null, null, null, null, null, null, 2, 'Account Monitoring - Reg. NGOs - Prior Reference Category', 114, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Repeated small value foreign inward remittance from unrelated parties followed by expenditure on specified activities such as purchase of tickets, hotel bookings etc', null, null, null, null, null, null, 3, 'Repeated small value foreign remittances for specified expenditures', 115, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Repeated small value inward remittance from unrelated parties followed by immediate cash withdrawal (through ATMs or other modes)', null, null, null, null, null, null, 3, 'Repeated small value inward remittances followed by cash withdrawal', 116, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Repeated small value withdrawals in sensitive locations', null, null, null, null, null, null, 3, 'Repeated small value withdrawals in sensitive locations', 117, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Account Monitoring - Structuring of cross border transactions to avoid reporting in Cross Border Wire Transfer Report(CBWTR)', null, null, null, null, null, null, 3, 'Structuring cross border transactions to avoid reporting', 118, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Afghan Drug Business - A company is used for making payments under international contracts for delivery of goods from India to Afghanistan and the company is not a contract party', null, null, null, null, null, null, 3, 'Payments under contract to Afghanistan where company is not a party', 119, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Afghan Drug Business - Large funds are received from or sent to Afghanistan as advances for export/ import without goods being exported/ imported', null, null, null, null, null, null, 3, 'Large funds sent/received to/from Afghanistan as advances without goods', 120, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Afghan Drug Business - Non residents remit funds to offshore companies and natural persons having offshore accounts', null, null, null, null, null, null, 3, 'Afghan drug business links to offshore accounts', 121, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Afghan Drug Business - Parties transacting in goods with Afghanistan which are not in the normal line of their declared business', null, null, null, null, null, null, 3, 'Parties transacting in goods with Afghanistan outside normal business line', 122, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Afghan Drug Business - Person getting cash deposits below threshold reporting limits are being followed by immediate ATM withdrawal in Afghanistan/Pakistan', null, null, null, null, null, null, 3, 'Cash deposits followed by immediate withdrawal in Afghanistan/Pakistan', 123, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Afghan Drug Business - Persons of Afghan nationality staying in India and sending multiple maximum permissible amounts to Afghanistan', null, null, null, null, null, null, 3, 'Afghan nationality sending multiple permissible amounts to Afghanistan', 124, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Afghan Drug Business - Students from other countries (having Afghan nationality) staying in India, maintaining more than one account and generating cash more than INR 10 lakh in a year', null, null, null, null, null, null, 3, 'Afghan students maintaining multiple accounts generating high cash', 125, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Afghan Drug Business - The accounts of persons show seasonal fluctuations in outbound transactions i.e. October - December and April - June coinciding with opium cultivation and harvesting', null, null, null, null, null, null, 3, 'Seasonal outbound fluctuations coinciding with opium harvesting', 126, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Credit Card Monitoring - Large credit balance in credit card', null, null, null, null, null, null, 2, 'Large credit balance in credit card', 127, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Credit Card Monitoring - Large repetitive credit card usage at the same merchant', null, null, null, null, null, null, 2, 'Large repetitive credit card usage at the same merchant', 128, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Credit Card Monitoring - Large value credit card transactions for purchase of high value goods', null, null, null, null, null, null, 2, 'Large value credit card transactions for high value goods', 129, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Credit Card Monitoring - Majority of credit card repayments in cash(repayments greater)', null, null, null, null, null, null, 2, 'Majority of credit card repayments in cash', 130, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Address found to be non existent or wrong', null, null, null, null, null, null, 3, 'Address found to be non-existent or wrong', 131, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Adverse media report about criminal activities of customer', null, null, null, null, null, null, 3, 'Adverse media report about criminal activities', 132, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Adverse media report about TF or terrorist activities of customer', null, null, null, null, null, null, 3, 'Adverse media report about terrorist financing/TF', 133, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Alert raised by other agents/subsidiaries /associates/other institutions', null, null, null, null, null, null, 2, 'Alert raised by other agents/subsidiaries/associates', 134, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Availing loan facility/ OD(Overdraft) facility against FDR(Fixed Deposit Receipt) within few days of creation', null, null, null, null, null, null, 2, 'Availing loan/OD facility against FDR within few days of creation', 135, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Complaint received from public', null, null, null, null, null, null, 2, 'Customer Due Diligence - Complaint received from public', 136, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Customer acting on behalf of a third party', null, null, null, null, null, null, 3, 'Customer acting on behalf of a third party', 137, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Customer avoiding nearer branches', null, null, null, null, null, null, 2, 'Customer avoiding nearer branches', 138, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Customer could not explain source of funds', null, null, null, null, null, null, 3, 'Customer could not explain source of funds', 139, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Customer did not complete transaction', null, null, null, null, null, null, 2, 'Customer did not complete transaction', 140, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Customer is being investigated for criminal offences', null, null, null, null, null, null, 3, 'Customer is being investigated for criminal offences', 141, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Customer is being investigated for TF offences', null, null, null, null, null, null, 3, 'Customer is being investigated for TF offences', 142, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Customer is nervous or over cautious', null, null, null, null, null, null, 2, 'Customer is nervous or over cautious', 143, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Customer left without opening account', null, null, null, null, null, null, 2, 'Customer left without opening account', 144, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Customer offered false or forged identification/address documents', null, null, null, null, null, null, 3, 'Customer offered false or forged ID/address documents', 145, 'FLAGGED', 'YES', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Customer provides inconsistent information', null, null, null, null, null, null, 2, 'Customer provides inconsistent information', 146, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Customer providing different details to avoid linkage', null, null, null, null, null, null, 3, 'Customer providing different details to avoid linkage', 147, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Customer wants to avoid reporting', null, null, null, null, null, null, 3, 'Customer wants to avoid reporting', 148, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Difficult to identify beneficial owner', null, null, null, null, null, null, 3, 'Difficult to identify beneficial owner', 149, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Directors are persons of very low means - individually they have nil or low net worth and do not have any substantial source of income', null, null, null, null, null, null, 3, 'Directors are persons of low net worth and no substantial source of income', 150, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Established Fraud Cases', null, null, null, null, null, null, 3, 'Customer Due Diligence - Established Fraud Cases', 151, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Frequent Locker operations', null, null, null, null, null, null, 2, 'Customer Due Diligence - Frequent Locker operations', 152, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Funds are transferred from the company to an unusually large number and different kind of beneficiaries(from different sectors/businesses)', null, null, null, null, null, null, 3, 'Funds transferred to large number of diverse beneficiaries', 153, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Generally no physical presence(other than a mailing address)', null, null, null, null, null, null, 3, 'Generally no physical presence (other than mailing address)', 154, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - High Forex Activity Authorised Dealer “ Category II(AD Cat-II) accounts', null, null, null, null, null, null, 3, 'High Forex Activity Authorised Dealer accounts', 155, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Little or no withdrawal from account for business purposes/ no recurrent business expenses', null, null, null, null, null, null, 2, 'Little or no withdrawal for business expenses', 156, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Multiple accounts by individual customer/company under various heads in a single branch', null, null, null, null, null, null, 3, 'Multiple accounts by individual customer under various heads', 157, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Multiple customers working as a group', null, null, null, null, null, null, 3, 'Multiple customers working as a group', 158, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Multiple customers working together', null, null, null, null, null, null, 3, 'Multiple customers working together', 159, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Payments have no stated purpose, do not have reference to goods or services, or identify only a contract or invoice number', null, null, null, null, null, null, 3, 'Payments have no stated purpose or reference', 160, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Rotation of funds between account of companies having same authorized signatory', null, null, null, null, null, null, 3, 'Rotation of funds between accounts with same authorized signatory', 161, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Transacting businesses i.e. entities doing business with the company share the same address or there are address related inconsistencies', null, null, null, null, null, null, 3, 'Transacting business entities sharing same address or inconsistencies', 162, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Customer Due Diligence - Transacting parties appear to be affiliated, conduct business out of a residential address or provide only a registered agent’s address', null, null, null, null, null, null, 3, 'Transacting parties conduct business out of residential or registered agent address', 163, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('FICN - Transaction(s) involving Fake Indian Currency Notes(FICN) - greater than', null, null, null, null, null, null, 3, 'Transaction involving Fake Indian Currency Notes (FICN)', 164, 'FLAGGED', 'YES', 'NO', 'NO', 'ACTIVE'),
('FICN(India-Nepal) - Cash deposits made in home bank accounts located on Indo-Nepal border areas in Bihar(mainly in districts East and West Champaran) with quick ATM withdrawals(within 2 days) in Malda(West Bengal) area or cash withdrawal from branches', null, null, null, null, null, null, 3, 'FICN links Indo-Nepal border cash deposits and Malda ATM withdrawals', 165, 'FLAGGED', 'YES', 'NO', 'NO', 'ACTIVE'),
('FICN(India-Nepal) - Frequent cash deposits made in bank accounts located in Malda if the cash is deposited in various different locations of the country e.g. Delhi/NCR, Karnataka, Gujarat, Tamil Nadu, Maharashtra etc. and withdrawn simultaneously at Malda', null, null, null, null, null, null, 3, 'Frequent cash deposits at different locations withdrawn at Malda', 166, 'FLAGGED', 'YES', 'NO', 'NO', 'ACTIVE'),
('Mutilated Indian Currency Notes - Transaction(s) involving mutilated Indian Currency Notes', null, null, null, null, null, null, 2, 'Transaction involving mutilated Indian Currency Notes', 167, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Name Screening - Match with FIU-IND alerts/ lists/ requests', null, null, null, null, null, null, 3, 'Name Screening - Match with FIU-IND alerts/lists/requests', 168, 'BLOCKED', 'YES', 'YES', 'NO', 'ACTIVE'),
('Name Screening - Match with other criminal lists', null, null, null, null, null, null, 3, 'Name Screening - Match with other criminal lists', 169, 'BLOCKED', 'YES', 'YES', 'NO', 'ACTIVE'),
('Name Screening - Match with other TF List', null, null, null, null, null, null, 3, 'Name Screening - Match with other TF List', 170, 'BLOCKED', 'YES', 'YES', 'NO', 'ACTIVE'),
('Name Screening - Match with UAPA List', null, null, null, null, null, null, 3, 'Name Screening - Match with UAPA List', 171, 'BLOCKED', 'YES', 'YES', 'NO', 'ACTIVE'),
('Name Screening - Match with UN List', null, null, null, null, null, null, 3, 'Name Screening - Match with UN List', 172, 'BLOCKED', 'YES', 'YES', 'NO', 'ACTIVE'),
('Non Customer Monitoring - Foreign exchange transactions for non-account holder transactions', null, null, null, null, null, null, 2, 'Foreign exchange transactions for non-account holder transactions', 173, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Non Customer Monitoring - Large value cash withdrawals against international card', null, null, null, null, null, null, 3, 'Large value cash withdrawals against international card', 174, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Non Customer Monitoring - Repeated small value cash withdrawals against international card', null, null, null, null, null, null, 3, 'Repeated small value cash withdrawals against international card', 175, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Overseas Direct Investment(ODI) - Non-submission of documentary evidence by the Indian Party under suspicious circumstances', null, null, null, null, null, null, 2, 'Non-submission of ODI documentary evidence', 176, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Shell Companies - Frequent transactions with entities located at high risk countries/ jurisdiction', null, null, null, null, null, null, 3, 'Frequent transactions with entities located in high risk countries', 177, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Shell Companies - Frequent transactions with entities located at, off shore financial centres', null, null, null, null, null, null, 3, 'Frequent transactions with entities located in off shore financial centres', 178, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Shell Companies - Immediate transfer of funds and very low minimum balance maintained in account', null, null, null, null, null, null, 3, 'Shell Companies - Immediate transfer of funds with low minimum balance', 179, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Terrorist Financing - Reg North East Insurgency(for Nagaland, Assam and Manipur)', null, null, null, null, null, null, 3, 'Terrorist Financing - Reg North East Insurgency', 180, 'BLOCKED', 'YES', 'YES', 'NO', 'ACTIVE'),
('Terrorist Financing - Regarding Maoist Insurgency', null, null, null, null, null, null, 3, 'Terrorist Financing - Regarding Maoist Insurgency', 181, 'BLOCKED', 'YES', 'YES', 'NO', 'ACTIVE'),
('Terrorist Financing - Transaction involving a location with terrorist incident', null, null, null, null, null, null, 3, 'Transaction involving a location with terrorist incident', 182, 'FLAGGED', 'YES', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - A customer deviates significantly from its historical pattern of trade activity(i.e. in terms of markets, monetary value, frequency of transactions, volume, or merchandise type)', null, null, null, null, null, null, 3, 'Customer deviates significantly from historical trade pattern', 183, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Advance for supply of goods or services is a major part/percentage of the total value of goods or services', null, null, null, null, null, null, 3, 'Trade Based Money Laundering - Advance for supply is a major part of value', 184, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Advance waivers provided or pre-accepted discrepancy(s) by the applicant and/ or the applicant is over-keen to waive discrepancy', null, null, null, null, null, null, 3, 'Advance waivers provided or applicant over-keen to waive discrepancy', 185, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Amount of advance is not in line with normal international trade for the kind of goods or services', null, null, null, null, null, null, 3, 'Amount of advance not in line with normal international trade', 186, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Booking of ticket abroad and subsequent cancelling and payment made to third party', null, null, null, null, null, null, 3, 'Booking ticket abroad with subsequent cancelling and third party payment', 187, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Circuitous route of shipment/ payment of goods inconsistent with normal geographic trade', null, null, null, null, null, null, 3, 'Circuitous route of shipment or payment inconsistent with trade', 188, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Consignment size is unreasonable compared to customer profile/capacity/size of business', null, null, null, null, null, null, 3, 'Consignment size unreasonable compared to customer profile', 189, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Conversion of financial assets to a virtual currency', null, null, null, null, null, null, 3, 'Conversion of financial assets to a virtual currency', 190, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Description of goods or services provided is vague', null, null, null, null, null, null, 3, 'Description of goods or services provided is vague', 191, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - EDPMS- Export advance received but goods not shipped', null, null, null, null, null, null, 3, 'EDPMS - Export advance received but goods not shipped', 192, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - EDPMS-Exports done but payment not received', null, null, null, null, null, null, 3, 'EDPMS - Exports done but payment not received', 193, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Frequent changes in payment instructions at the last minute or the use of repeatedly amended or frequently extended letters of credit without reasonable justification or for reasons like changes of beneficiary or location', null, null, null, null, null, null, 3, 'Frequent changes in payment instructions at the last minute or amended LC', 194, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - High proportion of high sea sales /merchanting trades', null, null, null, null, null, null, 3, 'High proportion of high sea sales / merchanting trades', 195, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - High value technical/ professional charges paid on account of consultancy', null, null, null, null, null, null, 3, 'High value technical/professional charges paid for consultancy', 196, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - IDPMS- Import advance sent but goods not received', null, null, null, null, null, null, 3, 'IDPMS - Import advance sent but goods not received', 197, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - IDPMS- Import done but payment not sent', null, null, null, null, null, null, 3, 'IDPMS - Import done but payment not sent', 198, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Import of goods from countries where underlying goods are not manufactured', null, null, null, null, null, null, 3, 'Import of goods from countries where underlying goods are not manufactured', 199, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Import payments being made against old bills after lapse of considerable period of time from import of goods, without appropriate justification and documentation', null, null, null, null, null, null, 3, 'Import payments against old bills without appropriate justification', 200, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Importer of goods or services not from same country from where wire(payment for import) originated', null, null, null, null, null, null, 3, 'Importer not from same country from where wire payment originated', 201, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Initial import remittances by customers', null, null, null, null, null, null, 3, 'Initial import remittances by customers', 202, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Inward remittance received from Exchange House for the purpose of trade settlements', null, null, null, null, null, null, 3, 'Inward remittance from Exchange House for trade settlements', 203, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Many proprietorship firms importing from same exporter from a foreign land', null, null, null, null, null, null, 3, 'Many proprietorship firms importing from same exporter from foreign land', 204, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Multiple advance remittances to single or multiple entities by the same entity within permissible ceiling', null, null, null, null, null, null, 3, 'Multiple advance remittances within permissible ceiling', 205, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Originator/beneficiary information missing in wire transfers', null, null, null, null, null, null, 3, 'Originator/beneficiary information missing in wire transfers', 206, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Outward remittance of same value from single customer. More than x transactions on last y days', null, null, null, null, null, null, 3, 'Outward remittance of same value from single customer', 207, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Outward remittance to same overseas party', null, null, null, null, null, null, 3, 'Outward remittance to same overseas party', 208, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Over/under invoicing of goods or services', null, null, null, null, null, null, 3, 'Over/under invoicing of goods or services', 209, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Receipt of multiple payments via internet payment service provider like Paypal, etc', null, null, null, null, null, null, 3, 'Receipt of multiple payments via internet payment service provider', 210, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Re-presentation of third-party trade / official document immediately after a turn-down for discrepancy', null, null, null, null, null, null, 3, 'Re-presentation of third-party trade/official document after turn-down', 211, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Routing of import payments above[X] value through India by a foreign based entity having operations and customer base outside India', null, null, null, null, null, null, 3, 'Routing of import payments through India by foreign entity', 212, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Submission/ payment of round figure bills', null, null, null, null, null, null, 3, 'Submission/ payment of round figure bills', 213, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Trade Based Money Laundering - Substantial inconsistencies between the information originally supplied and that contained in the documents', null, null, null, null, null, null, 3, 'Substantial inconsistencies in documentation supplied', 214, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - The LC contains non-standard clauses or phrases or has unusual characteristics', null, null, null, null, null, null, 3, 'The LC contains non-standard clauses or unusual characteristics', 215, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Transaction has no economic rationale', null, null, null, null, null, null, 3, 'Transaction has no economic rationale', 216, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Transaction inconsistent with business', null, null, null, null, null, null, 3, 'Transaction inconsistent with business', 217, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Transaction is unnecessarily complex', null, null, null, null, null, null, 3, 'Transaction is unnecessarily complex', 218, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Transactions not in-line with normal international trade for the given kind of goods and line of business of the parties involved', null, null, null, null, null, null, 3, 'Transactions not in-line with normal international trade', 219, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Transactions involving third parties which may not be contract parties(consignee and remitter are different)', null, null, null, null, null, null, 3, 'Transactions involving third parties which may not be contract parties', 220, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Transactions related to acquisition or sale of intangibles like specialised software, etc', null, null, null, null, null, null, 3, 'Transactions related to acquisition/sale of intangibles like software', 221, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Underlying goods or services involved in the trade transaction are of sensitive nature and/or the Value/Quantity of goods or services is not easily ascertainable', null, null, null, null, null, null, 3, 'Underlying goods/services of sensitive nature or value not easily ascertainable', 222, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Underlying goods or services not in line with customer''s profile and declared business', null, null, null, null, null, null, 3, 'Underlying goods/services not in line with customer profile and business', 223, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Trade Based Money Laundering - Wash sales or round trip sales - Accounts debited and then immediately credited or vice versa for related purchase/sale', null, null, null, null, null, null, 3, 'Wash sales or round trip sales on account debited/credited', 224, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High value cash transactions by dealer in precious metal or stone', null, null, null, null, null, null, 3, 'High value cash transactions by dealer in precious metal or stone', 225, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High value cash transactions in NPOs', null, null, null, null, null, null, 3, 'High value cash transactions in NPOs', 226, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('High value cash transactions pertaining to accounts of real estate agents and dealers', null, null, null, null, null, null, 3, 'High value cash transactions pertaining to accounts of real estate agents', 227, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Non Customer Monitoring - Foreign exchange transactions for non-account holder transactions(remittance)', null, null, null, null, null, null, 2, 'Non Customer Monitoring - Forex transactions for non-account holder', 228, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Credit Card Monitoring - Majority of credit card repayments in cash(repayments totalling)', null, null, null, null, null, null, 2, 'Credit Card Monitoring - Majority of repayments in cash', 229, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Terrorist Financing - Reg North East Insurgency(for Nagaland, Assam and Manipur) - Deposited Money Into Fix Deposits', null, null, null, null, null, null, 3, 'Terrorist Financing - North East Insurgency fix deposits', 230, 'BLOCKED', 'YES', 'YES', 'NO', 'ACTIVE'),
('Terrorist Financing - Reg North East Insurgency(for Nagaland, Assam and Manipur) - withdrawn as cash/ by cheque', null, null, null, null, null, null, 3, 'Terrorist Financing - North East Insurgency cash/cheque withdrawals', 231, 'BLOCKED', 'YES', 'YES', 'NO', 'ACTIVE'),
('Terrorist Financing - Reg North East Insurgency(for Nagaland, Assam and Manipur) - business or other legitimate activity', null, null, null, null, null, null, 3, 'Terrorist Financing - North East Insurgency business activity', 232, 'BLOCKED', 'YES', 'YES', 'NO', 'ACTIVE'),
('Account Monitoring - Reg. NGOs - Receipt of funds in account', null, null, null, null, null, null, 2, 'Account Monitoring - Reg. NGOs - Receipt of funds in account', 233, 'FLAGGED', 'NO', 'NO', 'NO', 'ACTIVE'),
('Terrorist Financing - Regarding Maoist Insurgency - Account funded in cash outside', null, null, null, null, null, null, 3, 'Maoist Insurgency - Account funded in cash outside', 234, 'BLOCKED', 'YES', 'YES', 'NO', 'ACTIVE'),
('FICN - Transaction(s) involving Fake Indian Currency Notes(FICN) - aggregating to greater', null, null, null, null, null, null, 3, 'FICN - Transaction involving Fake Indian Currency Notes', 235, 'BLOCKED', 'YES', 'YES', 'NO', 'ACTIVE');
</sql>
</changeSet>
</databaseChangeLog>
@@ -0,0 +1,416 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-4.13.xsd">
<!-- Evaluable transaction-monitoring rule catalog. Distinct from m_client_risk_rule (KYC-time,
client-profile scoring) - these rules are checked against live transactions as they post. -->
<changeSet author="fineract" id="0433-1">
<preConditions onFail="MARK_RAN">
<not><tableExists tableName="m_aml_transaction_rule"/></not>
</preConditions>
<createTable tableName="m_aml_transaction_rule">
<column name="id" type="BIGINT" autoIncrement="true">
<constraints primaryKey="true" nullable="false"/>
</column>
<column name="rule_code" type="VARCHAR(50)">
<constraints nullable="false" unique="true"/>
</column>
<column name="description" type="VARCHAR(500)">
<constraints nullable="false"/>
</column>
<!-- SAVINGS | LOAN | TRANSFER | ALL -->
<column name="applies_to" type="VARCHAR(20)">
<constraints nullable="false"/>
</column>
<column name="threshold_amount" type="DECIMAL(19,6)">
<constraints nullable="true"/>
</column>
<!-- THRESHOLD | STRUCTURING | VELOCITY -->
<column name="rule_type" type="VARCHAR(20)">
<constraints nullable="false"/>
</column>
<column name="window_days" type="INT">
<constraints nullable="true"/>
</column>
<!-- traceability back to the seeded 221-rule AML catalog in m_client_risk_rule -->
<column name="source_client_risk_rule_id" type="BIGINT">
<constraints nullable="true"/>
</column>
<column name="is_active" type="BOOLEAN" defaultValueBoolean="true">
<constraints nullable="false"/>
</column>
</createTable>
</changeSet>
<changeSet author="fineract" id="0433-2">
<preConditions onFail="MARK_RAN">
<not><foreignKeyConstraintExists foreignKeyName="FK_m_aml_transaction_rule_source_risk_rule"/></not>
</preConditions>
<addForeignKeyConstraint baseTableName="m_aml_transaction_rule" baseColumnNames="source_client_risk_rule_id"
referencedTableName="m_client_risk_rule" referencedColumnNames="id"
constraintName="FK_m_aml_transaction_rule_source_risk_rule"/>
</changeSet>
<!-- One row per rule hit on a live transaction. Fires regardless of the client's current
KYC risk category - risk category affects re-KYC cadence only, never alert suppression. -->
<changeSet author="fineract" id="0433-3">
<preConditions onFail="MARK_RAN">
<not><tableExists tableName="m_aml_alert"/></not>
</preConditions>
<createTable tableName="m_aml_alert">
<column name="id" type="BIGINT" autoIncrement="true">
<constraints primaryKey="true" nullable="false"/>
</column>
<!-- SAVINGS | LOAN | TRANSFER -->
<column name="transaction_type" type="VARCHAR(20)">
<constraints nullable="false"/>
</column>
<column name="transaction_id" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="client_id" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="rule_id" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="amount" type="DECIMAL(19,6)">
<constraints nullable="false"/>
</column>
<column name="currency_code" type="VARCHAR(3)">
<constraints nullable="true"/>
</column>
<column name="raised_on" type="DATETIME">
<constraints nullable="false"/>
</column>
<!-- RAISED | UNDER_REVIEW | WHITELISTED | ESCALATED -->
<column name="status" type="VARCHAR(20)" defaultValue="RAISED">
<constraints nullable="false"/>
</column>
<column name="reviewed_by" type="BIGINT">
<constraints nullable="true"/>
</column>
<column name="reviewed_on" type="DATETIME">
<constraints nullable="true"/>
</column>
<column name="review_notes" type="VARCHAR(1000)">
<constraints nullable="true"/>
</column>
<!-- WHITELIST | ESCALATE, set by the first-level AML Officer -->
<column name="disposition" type="VARCHAR(20)">
<constraints nullable="true"/>
</column>
<column name="created_by" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="created_on_utc" type="DATETIME">
<constraints nullable="false"/>
</column>
<column name="last_modified_by" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="last_modified_on_utc" type="DATETIME">
<constraints nullable="false"/>
</column>
<column name="version" type="BIGINT" defaultValueNumeric="0">
<constraints nullable="false"/>
</column>
</createTable>
</changeSet>
<changeSet author="fineract" id="0433-4">
<preConditions onFail="MARK_RAN">
<not><foreignKeyConstraintExists foreignKeyName="FK_m_aml_alert_client"/></not>
</preConditions>
<addForeignKeyConstraint baseTableName="m_aml_alert" baseColumnNames="client_id"
referencedTableName="m_client" referencedColumnNames="id"
constraintName="FK_m_aml_alert_client"/>
</changeSet>
<changeSet author="fineract" id="0433-5">
<preConditions onFail="MARK_RAN">
<not><foreignKeyConstraintExists foreignKeyName="FK_m_aml_alert_rule"/></not>
</preConditions>
<addForeignKeyConstraint baseTableName="m_aml_alert" baseColumnNames="rule_id"
referencedTableName="m_aml_transaction_rule" referencedColumnNames="id"
constraintName="FK_m_aml_alert_rule"/>
</changeSet>
<changeSet author="fineract" id="0433-6">
<preConditions onFail="MARK_RAN">
<not><indexExists indexName="IDX_m_aml_alert_client_status"/></not>
</preConditions>
<createIndex indexName="IDX_m_aml_alert_client_status" tableName="m_aml_alert">
<column name="client_id"/>
<column name="status"/>
</createIndex>
</changeSet>
<!-- Created when an alert is escalated past first-level review. concluded_on is the Principal
Officer's conclusion date - the RBI-mandated 7-working-day FIU filing clock starts here,
never at the alert or transaction date. -->
<changeSet author="fineract" id="0433-7">
<preConditions onFail="MARK_RAN">
<not><tableExists tableName="m_aml_str_case"/></not>
</preConditions>
<createTable tableName="m_aml_str_case">
<column name="id" type="BIGINT" autoIncrement="true">
<constraints primaryKey="true" nullable="false"/>
</column>
<column name="alert_id" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="client_id" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="assigned_po" type="BIGINT">
<constraints nullable="true"/>
</column>
<column name="investigation_notes" type="VARCHAR(2000)">
<constraints nullable="true"/>
</column>
<column name="source_of_funds_notes" type="VARCHAR(2000)">
<constraints nullable="true"/>
</column>
<!-- NOT_SUSPICIOUS | SUSPICIOUS -->
<column name="conclusion" type="VARCHAR(20)">
<constraints nullable="true"/>
</column>
<column name="concluded_by" type="BIGINT">
<constraints nullable="true"/>
</column>
<column name="concluded_on" type="DATE">
<constraints nullable="true"/>
</column>
<column name="fiu_due_date" type="DATE">
<constraints nullable="true"/>
</column>
<column name="str_filed_on" type="DATE">
<constraints nullable="true"/>
</column>
<column name="str_reference_no" type="VARCHAR(100)">
<constraints nullable="true"/>
</column>
<!-- OPEN | CONCLUDED_CLEAR | CONCLUDED_SUSPICIOUS | FILED -->
<column name="status" type="VARCHAR(25)" defaultValue="OPEN">
<constraints nullable="false"/>
</column>
<column name="created_by" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="created_on_utc" type="DATETIME">
<constraints nullable="false"/>
</column>
<column name="last_modified_by" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="last_modified_on_utc" type="DATETIME">
<constraints nullable="false"/>
</column>
<column name="version" type="BIGINT" defaultValueNumeric="0">
<constraints nullable="false"/>
</column>
</createTable>
</changeSet>
<changeSet author="fineract" id="0433-8">
<preConditions onFail="MARK_RAN">
<not><foreignKeyConstraintExists foreignKeyName="FK_m_aml_str_case_alert"/></not>
</preConditions>
<addForeignKeyConstraint baseTableName="m_aml_str_case" baseColumnNames="alert_id"
referencedTableName="m_aml_alert" referencedColumnNames="id"
constraintName="FK_m_aml_str_case_alert"/>
</changeSet>
<changeSet author="fineract" id="0433-9">
<preConditions onFail="MARK_RAN">
<not><foreignKeyConstraintExists foreignKeyName="FK_m_aml_str_case_client"/></not>
</preConditions>
<addForeignKeyConstraint baseTableName="m_aml_str_case" baseColumnNames="client_id"
referencedTableName="m_client" referencedColumnNames="id"
constraintName="FK_m_aml_str_case_client"/>
</changeSet>
<changeSet author="fineract" id="0433-10">
<preConditions onFail="MARK_RAN">
<not><indexExists indexName="IDX_m_aml_str_case_client"/></not>
</preConditions>
<createIndex indexName="IDX_m_aml_str_case_client" tableName="m_aml_str_case">
<column name="client_id"/>
</createIndex>
</changeSet>
<!-- Monthly mechanical CTR batch header - threshold-based, no PO judgment involved. -->
<changeSet author="fineract" id="0433-11">
<preConditions onFail="MARK_RAN">
<not><tableExists tableName="m_aml_ctr_report"/></not>
</preConditions>
<createTable tableName="m_aml_ctr_report">
<column name="id" type="BIGINT" autoIncrement="true">
<constraints primaryKey="true" nullable="false"/>
</column>
<column name="report_month" type="VARCHAR(7)">
<!-- yyyy-MM -->
<constraints nullable="false"/>
</column>
<column name="generated_on" type="DATETIME">
<constraints nullable="false"/>
</column>
<column name="record_count" type="INT" defaultValueNumeric="0">
<constraints nullable="false"/>
</column>
<column name="file_reference" type="VARCHAR(150)">
<constraints nullable="true"/>
</column>
<!-- DRAFT | GENERATED | SUBMITTED -->
<column name="status" type="VARCHAR(20)" defaultValue="DRAFT">
<constraints nullable="false"/>
</column>
<column name="submitted_on" type="DATETIME">
<constraints nullable="true"/>
</column>
<column name="created_by" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="created_on_utc" type="DATETIME">
<constraints nullable="false"/>
</column>
<column name="last_modified_by" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="last_modified_on_utc" type="DATETIME">
<constraints nullable="false"/>
</column>
<column name="version" type="BIGINT" defaultValueNumeric="0">
<constraints nullable="false"/>
</column>
</createTable>
</changeSet>
<changeSet author="fineract" id="0433-12">
<preConditions onFail="MARK_RAN">
<not><indexExists indexName="IDX_m_aml_ctr_report_month"/></not>
</preConditions>
<createIndex indexName="IDX_m_aml_ctr_report_month" tableName="m_aml_ctr_report" unique="true">
<column name="report_month"/>
</createIndex>
</changeSet>
<!-- Lines feeding a CTR report: individually-large cash transactions, plus is_connected_group
rows for clients whose smaller transactions sum above the monthly threshold (structuring). -->
<changeSet author="fineract" id="0433-13">
<preConditions onFail="MARK_RAN">
<not><tableExists tableName="m_aml_ctr_report_line"/></not>
</preConditions>
<createTable tableName="m_aml_ctr_report_line">
<column name="id" type="BIGINT" autoIncrement="true">
<constraints primaryKey="true" nullable="false"/>
</column>
<column name="ctr_report_id" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="transaction_type" type="VARCHAR(20)">
<constraints nullable="false"/>
</column>
<column name="transaction_id" type="BIGINT">
<constraints nullable="true"/>
</column>
<column name="client_id" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="amount" type="DECIMAL(19,6)">
<constraints nullable="false"/>
</column>
<column name="is_connected_group" type="BOOLEAN" defaultValueBoolean="false">
<constraints nullable="false"/>
</column>
</createTable>
</changeSet>
<changeSet author="fineract" id="0433-14">
<preConditions onFail="MARK_RAN">
<not><foreignKeyConstraintExists foreignKeyName="FK_m_aml_ctr_report_line_report"/></not>
</preConditions>
<addForeignKeyConstraint baseTableName="m_aml_ctr_report_line" baseColumnNames="ctr_report_id"
referencedTableName="m_aml_ctr_report" referencedColumnNames="id"
constraintName="FK_m_aml_ctr_report_line_report"/>
</changeSet>
<!-- Immutable, append-only audit trail answering "why did this client's risk category change".
Backs the AML menu's existing "Risk Update History Report" item, which had no data behind it. -->
<changeSet author="fineract" id="0433-15">
<preConditions onFail="MARK_RAN">
<not><tableExists tableName="m_client_risk_category_history"/></not>
</preConditions>
<createTable tableName="m_client_risk_category_history">
<column name="id" type="BIGINT" autoIncrement="true">
<constraints primaryKey="true" nullable="false"/>
</column>
<column name="client_id" type="BIGINT">
<constraints nullable="false"/>
</column>
<column name="previous_category" type="INT">
<constraints nullable="false"/>
</column>
<column name="new_category" type="INT">
<constraints nullable="false"/>
</column>
<column name="reason" type="VARCHAR(500)">
<constraints nullable="false"/>
</column>
<!-- AML_AUTO_ESCALATION | MANUAL -->
<column name="triggered_by" type="VARCHAR(30)">
<constraints nullable="false"/>
</column>
<column name="str_case_id" type="BIGINT">
<constraints nullable="true"/>
</column>
<column name="changed_on" type="DATETIME">
<constraints nullable="false"/>
</column>
<column name="changed_by" type="BIGINT">
<constraints nullable="false"/>
</column>
</createTable>
</changeSet>
<changeSet author="fineract" id="0433-16">
<preConditions onFail="MARK_RAN">
<not><foreignKeyConstraintExists foreignKeyName="FK_m_client_risk_category_history_client"/></not>
</preConditions>
<addForeignKeyConstraint baseTableName="m_client_risk_category_history" baseColumnNames="client_id"
referencedTableName="m_client" referencedColumnNames="id"
constraintName="FK_m_client_risk_category_history_client"/>
</changeSet>
<changeSet author="fineract" id="0433-17">
<preConditions onFail="MARK_RAN">
<not><foreignKeyConstraintExists foreignKeyName="FK_m_client_risk_category_history_str_case"/></not>
</preConditions>
<addForeignKeyConstraint baseTableName="m_client_risk_category_history" baseColumnNames="str_case_id"
referencedTableName="m_aml_str_case" referencedColumnNames="id"
constraintName="FK_m_client_risk_category_history_str_case"/>
</changeSet>
</databaseChangeLog>
@@ -0,0 +1,61 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-4.13.xsd">
<!--
Starter set of MACHINE-EVALUABLE transaction rules, curated from the 221-rule catalog
already seeded in m_client_risk_rule (0430_seed_aml_compliance_rules.xml), whose
order_position column is the rule's Srno. Most of the 221 rules are qualitative /
KYC-time judgment calls (e.g. "Customer is nervous or over cautious") and are not
included here - only ones with a clear, live-transaction-checkable condition are.
Threshold numbers marked "illustrative default" mirror the bank's own Rules Parameter
screens where a configured value was available (Rules 1, 6, 10, 11, 12, 13); others are
reasonable starting points meant to be tuned via the AML rule administration UI.
-->
<changeSet author="fineract" id="0434-1">
<preConditions onFail="MARK_RAN">
<sqlCheck expectedResult="0">SELECT COUNT(*) FROM m_aml_transaction_rule</sqlCheck>
</preConditions>
<sql>
INSERT INTO m_aml_transaction_rule (rule_code, description, applies_to, threshold_amount, rule_type, window_days, source_client_risk_rule_id, is_active)
VALUES
('CTR_THRESHOLD_10L', 'Mandatory CTR reporting threshold - single cash transaction of INR 10,00,000 or more', 'ALL', 1000000, 'THRESHOLD', null, null, true),
('STRUCTURED_CTR_10L_MONTHLY', 'Connected cash transactions summing to INR 10,00,000 or more within a calendar month (CTR aggregation rule)', 'ALL', 1000000, 'STRUCTURING', 30, null, true),
('LARGE_CASH_TXN_25L', 'Large cash transaction', 'ALL', 2500000, 'THRESHOLD', null, (SELECT id FROM m_client_risk_rule WHERE order_position = 6), true),
('STRUCTURING_BELOW_10L', 'Splitting of cash deposits just below INR 10,00,000 in multiple accounts in a month', 'SAVINGS', 1000000, 'STRUCTURING', 30, (SELECT id FROM m_client_risk_rule WHERE order_position = 28), true),
('STRUCTURING_BELOW_50K', 'Splitting of cash deposits just below INR 50,000', 'SAVINGS', 50000, 'STRUCTURING', 30, (SELECT id FROM m_client_risk_rule WHERE order_position = 29), true),
('FREQUENT_LOW_CASH_DEPOSIT', 'Frequent low cash deposits', 'SAVINGS', 50000, 'VELOCITY', 7, (SELECT id FROM m_client_risk_rule WHERE order_position = 30), true),
('FREQUENT_LOW_CASH_WITHDRAWAL', 'Frequent low cash withdrawals', 'SAVINGS', 50000, 'VELOCITY', 7, (SELECT id FROM m_client_risk_rule WHERE order_position = 31), true),
('FREQUENT_CASH_NEAR_10L', 'Frequent cash deposits just below INR 10,00,000', 'SAVINGS', 1000000, 'STRUCTURING', 30, (SELECT id FROM m_client_risk_rule WHERE order_position = 65), true),
('RTGS_HIGH_VALUE', 'Monitoring RTGS Transactions', 'TRANSFER', 2000000, 'THRESHOLD', null, (SELECT id FROM m_client_risk_rule WHERE order_position = 12), true),
('JEWELLER_ACCOUNT_LARGE_TXN', 'Monitoring accounts of Jewellers', 'ALL', 2000000, 'THRESHOLD', null, (SELECT id FROM m_client_risk_rule WHERE order_position = 13), true),
('CHARITABLE_ORG_CASH_WITHDRAWAL', 'Substantial cash withdrawals in accounts of charitable organization', 'SAVINGS', 50000, 'THRESHOLD', null, (SELECT id FROM m_client_risk_rule WHERE order_position = 10), true),
('PEP_ACCOUNT_MONITORING', 'Monitoring accounts of PEP (politically exposed person)', 'ALL', 50000, 'THRESHOLD', null, (SELECT id FROM m_client_risk_rule WHERE order_position = 11), true),
('NEW_ACCOUNT_LARGE_TXN', 'New account Large transaction', 'ALL', 500000, 'THRESHOLD', 30, (SELECT id FROM m_client_risk_rule WHERE order_position = 14), true),
('RAPID_MOVEMENT_IN_ACCOUNTS', 'Rapid Movement in accounts (same-day credit followed by debit)', 'SAVINGS', null, 'VELOCITY', 1, (SELECT id FROM m_client_risk_rule WHERE order_position = 24), true),
('LOAN_REPAYMENT_IN_CASH', 'Repayment of loan in cash', 'LOAN', 200000, 'THRESHOLD', null, (SELECT id FROM m_client_risk_rule WHERE order_position = 73), true);
</sql>
</changeSet>
</databaseChangeLog>
@@ -0,0 +1,129 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
for licensing details.
-->
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog
http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-4.1.xsd">
<!-- Step 1: permissions -->
<changeSet id="0435_insert_menu_aml_compliance_permission" author="fineract">
<sql>
INSERT INTO m_permission (grouping, code, entity_name, action_name, can_maker_checker)
SELECT 'heading_menu', 'MENU_AML_COMPLIANCE', 'MENU', 'AML_COMPLIANCE', false
WHERE NOT EXISTS (
SELECT 1 FROM m_permission WHERE code = 'MENU_AML_COMPLIANCE'
);
</sql>
<rollback>
DELETE FROM m_permission WHERE code = 'MENU_AML_COMPLIANCE';
</rollback>
</changeSet>
<changeSet id="0435_insert_review_aml_alert_permission" author="fineract">
<sql>
INSERT INTO m_permission (grouping, code, entity_name, action_name, can_maker_checker)
SELECT 'portfolio', 'REVIEW_AML_ALERT', 'AML_ALERT', 'REVIEW', false
WHERE NOT EXISTS (
SELECT 1 FROM m_permission WHERE code = 'REVIEW_AML_ALERT'
);
</sql>
<rollback>
DELETE FROM m_permission WHERE code = 'REVIEW_AML_ALERT';
</rollback>
</changeSet>
<!--
First-level AML Officer disposition on an alert: WHITELIST (close as false positive) or
ESCALATE (creates the m_aml_str_case row for Principal Officer review).
-->
<changeSet id="0435_insert_conclude_aml_str_permission" author="fineract">
<sql>
INSERT INTO m_permission (grouping, code, entity_name, action_name, can_maker_checker)
SELECT 'portfolio', 'CONCLUDE_AML_STR', 'AML_STR_CASE', 'CONCLUDE', false
WHERE NOT EXISTS (
SELECT 1 FROM m_permission WHERE code = 'CONCLUDE_AML_STR'
);
</sql>
<rollback>
DELETE FROM m_permission WHERE code = 'CONCLUDE_AML_STR';
</rollback>
</changeSet>
<!-- Step 2: roles -->
<changeSet id="0435_create_aml_officer_role" author="fineract">
<sql>
INSERT INTO m_role (name, description, is_disabled)
SELECT 'AML Officer', 'First-level reviewer of AML transaction-monitoring alerts: triages alerts and either whitelists or escalates to the Principal Officer.', false
WHERE NOT EXISTS (
SELECT 1 FROM m_role WHERE LOWER(name) = 'aml officer'
);
</sql>
<rollback>
DELETE FROM m_role_permission WHERE role_id = (SELECT id FROM m_role WHERE LOWER(name) = 'aml officer');
DELETE FROM m_role WHERE LOWER(name) = 'aml officer';
</rollback>
</changeSet>
<changeSet id="0435_create_principal_officer_role" author="fineract">
<sql>
INSERT INTO m_role (name, description, is_disabled)
SELECT 'Principal Officer', 'Statutory PMLA/RBI-designated officer. Concludes escalated AML alerts as suspicious or not, and is the sole authority for STR filing to FIU-IND.', false
WHERE NOT EXISTS (
SELECT 1 FROM m_role WHERE LOWER(name) = 'principal officer'
);
</sql>
<rollback>
DELETE FROM m_role_permission WHERE role_id = (SELECT id FROM m_role WHERE LOWER(name) = 'principal officer');
DELETE FROM m_role WHERE LOWER(name) = 'principal officer';
</rollback>
</changeSet>
<!-- Step 3: grant permissions to roles -->
<changeSet id="0435_grant_permissions_to_aml_officer" author="fineract">
<sql>
INSERT INTO m_role_permission (role_id, permission_id)
SELECT r.id, p.id
FROM m_role r, m_permission p
WHERE LOWER(r.name) = 'aml officer'
AND p.code IN ('MENU_AML_COMPLIANCE', 'REVIEW_AML_ALERT')
AND NOT EXISTS (
SELECT 1 FROM m_role_permission rp
WHERE rp.role_id = r.id AND rp.permission_id = p.id
);
</sql>
<rollback>
DELETE FROM m_role_permission
WHERE role_id = (SELECT id FROM m_role WHERE LOWER(name) = 'aml officer');
</rollback>
</changeSet>
<!--
Principal Officer also gets REVIEW_AML_ALERT (can perform first-level review directly on
single-tier cases) in addition to the CONCLUDE authority that is exclusive to this role.
-->
<changeSet id="0435_grant_permissions_to_principal_officer" author="fineract">
<sql>
INSERT INTO m_role_permission (role_id, permission_id)
SELECT r.id, p.id
FROM m_role r, m_permission p
WHERE LOWER(r.name) = 'principal officer'
AND p.code IN ('MENU_AML_COMPLIANCE', 'REVIEW_AML_ALERT', 'CONCLUDE_AML_STR')
AND NOT EXISTS (
SELECT 1 FROM m_role_permission rp
WHERE rp.role_id = r.id AND rp.permission_id = p.id
);
</sql>
<rollback>
DELETE FROM m_role_permission
WHERE role_id = (SELECT id FROM m_role WHERE LOWER(name) = 'principal officer');
</rollback>
</changeSet>
</databaseChangeLog>
@@ -0,0 +1,68 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
distributed with this work for additional information
regarding copyright ownership. The ASF licenses this file
to you under the Apache License, Version 2.0 (the
"License"); you may not use this file except in compliance
with the License. You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing,
software distributed under the License is distributed on an
"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
KIND, either express or implied. See the License for the
specific language governing permissions and limitations
under the License.
-->
<databaseChangeLog xmlns="http://www.liquibase.org/xml/ns/dbchangelog"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.liquibase.org/xml/ns/dbchangelog http://www.liquibase.org/xml/ns/dbchangelog/dbchangelog-4.13.xsd">
<!--
Repairs schema drift on m_client_risk_rule: environments where the table
was created before 0428_add_client_risk_rules.xml was authored are missing
these columns even though 0428's changesets are recorded as already run
(so Liquibase will never retry them). Guarded with columnExists so this
is a no-op anywhere the columns are already present.
-->
<changeSet author="fineract" id="0436-1">
<preConditions onFail="MARK_RAN">
<not><columnExists tableName="m_client_risk_rule" columnName="legal_form_id"/></not>
</preConditions>
<addColumn tableName="m_client_risk_rule">
<column name="legal_form_id" type="INT"/>
<column name="occupation_category_cv_id" type="BIGINT"/>
<column name="occupation_cv_id" type="BIGINT"/>
<column name="min_monthly_income" type="DECIMAL(19,6)"/>
<column name="max_monthly_income" type="DECIMAL(19,6)"/>
<column name="min_annual_income" type="DECIMAL(19,6)"/>
<column name="max_annual_income" type="DECIMAL(19,6)"/>
<column name="min_annual_turnover" type="DECIMAL(19,6)"/>
<column name="max_annual_turnover" type="DECIMAL(19,6)"/>
</addColumn>
</changeSet>
<changeSet author="fineract" id="0436-2">
<preConditions onFail="MARK_RAN">
<not><foreignKeyConstraintExists foreignKeyName="FK_m_client_risk_rule_occupation_category_cv_id"/></not>
</preConditions>
<addForeignKeyConstraint baseTableName="m_client_risk_rule" baseColumnNames="occupation_category_cv_id"
referencedTableName="m_code_value" referencedColumnNames="id"
constraintName="FK_m_client_risk_rule_occupation_category_cv_id" />
</changeSet>
<changeSet author="fineract" id="0436-3">
<preConditions onFail="MARK_RAN">
<not><foreignKeyConstraintExists foreignKeyName="FK_m_client_risk_rule_occupation_cv_id"/></not>
</preConditions>
<addForeignKeyConstraint baseTableName="m_client_risk_rule" baseColumnNames="occupation_cv_id"
referencedTableName="m_code_value" referencedColumnNames="id"
constraintName="FK_m_client_risk_rule_occupation_cv_id" />
</changeSet>
</databaseChangeLog>