VerityLayer Partner Onboarding Guide
Welcome to VerityLayer
VerityLayer is a comprehensive Governance, Risk, and Compliance (GRC) platform with integrated Security Information and Event Management (SIEM) capabilities. This guide will help you deploy and manage VerityLayer for your customers. ---Platform Overview
What is VerityLayer?
VerityLayer is an enterprise-grade GRC platform that provides: Core Modules:- Risk Management - Risk register, assessment, and treatment
- Vulnerability Management - Vulnerability tracking and remediation
- Asset Management - IT asset inventory and lifecycle management
- SIEM - Security monitoring, alerting, and incident response
- Compliance Management - Framework compliance tracking
- Vendor Management - Third-party risk assessment
- Business Continuity - BCDR planning and testing
- AutoPentest - Automated penetration testing
- Patch Management - Security patch tracking
Key Features
Multi-Tenant Architecture:
- Isolated databases per organization
- Complete data separation
- Customer-owned database support
- Flexible hosting options
- Role-based access control (RBAC)
- AES-256-GCM encryption
- Audit trails
- Session management
- Connection pooling
- Horizontal scaling
- Cloud-ready architecture
Deployment Options
Option 1: Managed SaaS (Recommended)
You host everything:- Central application server
- Central SaaS database
- Tenant databases (one per customer)
- Full control
- Easier management
- Predictable costs
---
Option 2: Hybrid Hosting
You host:- Central application server
- Central SaaS database
- Their tenant database (on their cloud/infrastructure)
- Customer data sovereignty
- Compliance with data residency requirements
- Customer control over their data
---
Option 3: Customer On-Premise
Customer hosts:- Everything (application + databases)
- Software license
- Support and updates
- Maximum customer control
- Air-gapped deployments possible
---
Quick Start Guide
Prerequisites
Server Requirements:- OS: Linux (Ubuntu 20.04+ recommended) or Windows Server
- Web Server: Apache 2.4+ or Nginx
- PHP: 7.4+ (8.0+ recommended)
- Database: MySQL 8.0+ or MariaDB 10.5+
- Memory: 4GB minimum, 8GB+ recommended
- Storage: 50GB+ (depends on customer count)
- mysqli
- openssl
- json
- mbstring
- curl
- gd
- zip
Installation Steps
1. Deploy Application
``bash
Clone or extract VerityLayer
cd /var/www/
unzip veritylayer-v1.0.zip
cd Risk\ APP\ AI
Set permissions
chown -R www-data:www-data .
chmod -R 755 .
chmod -R 775 storage/ logs/
`
2. Configure Database
`bash
Create central SaaS database
mysql -u root -p
`
`sql
CREATE DATABASE veritylayer_saas CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci;
CREATE USER 'veritylayer'@'localhost' IDENTIFIED BY 'secure_password_here';
GRANT ALL PRIVILEGES ON veritylayer_saas.* TO 'veritylayer'@'localhost';
FLUSH PRIVILEGES;
EXIT;
`
`bash
Import schema
mysql -u veritylayer -p veritylayer_saas < database/schema.sql
`
3. Configure Application
Edit db_connect.php:
`php
define('DB_HOST', 'localhost');
define('DB_USER', 'veritylayer');
define('DB_PASS', 'secure_password_here');
define('DB_NAME', 'veritylayer_saas');
`
Edit includes/config.php:
`php
// Multi-tenant configuration
define('TENANT_DB_MIGRATION', false); // Set to true when ready
define('DB_ENCRYPTION_KEY', 'generate-secure-key-here');
// Generate key: php -r "echo bin2hex(random_bytes(32));"
`
4. Install Multi-Tenant Tables
`bash
php database/install_org_db_connections.php
`
5. Create Super Admin
`bash
php admin/create_super_admin.php
`
Follow prompts to create your super admin account.
6. Configure Web Server
Apache (/etc/apache2/sites-available/veritylayer.conf):
`apache
ServerName veritylayer.yourdomain.com
DocumentRoot /var/www/veritylayer
AllowOverride All
Require all granted
ErrorLog ${APACHE_LOG_DIR}/veritylayer_error.log
CustomLog ${APACHE_LOG_DIR}/veritylayer_access.log combined
`
`bash
a2ensite veritylayer
a2enmod rewrite
systemctl restart apache2
`
7. Test Installation
Visit: http://veritylayer.yourdomain.com
Login with super admin credentials.
---
Customer Onboarding
Step 1: Create Organization
Via Web UI:
Login as super admin
Navigate to Super Admin → Organizations
Click Create Organization
Fill in details:
- Organization Name
- Contact Email
- Subscription Plan
- Max Users
Click Create
Via CLI:
`bash
php admin/create_organization.php \
--name="Acme Corporation" \
--email="admin@acme.com" \
--plan="professional" \
--max-users=50
`
---
Step 2: Provision Tenant Database
Scenario A: Managed Hosting (You host tenant DB)
`bash
php tenant-db-setup/setup_wizard.php \
--scenario=managed \
--org-id=1
`
This will:
- Create database:
org_1_db
Create user: org_1_user
Deploy schema
Register connection
Test connection
Scenario B: Customer Cloud (Customer provides DB)
`bash php tenant-db-setup/setup_wizard.php \ --scenario=customer_cloud \ --org-id=1 `
You'll be prompted for:
- Database host
- Database name
- Database user
- Database password
- SSL certificate (optional)
Scenario C: Customer On-Premise
`bash php tenant-db-setup/setup_wizard.php \ --scenario=customer_onprem \ --org-id=1 `
Requires network connectivity to customer infrastructure.
---
Step 3: Create Organization Admin
Via Web UI:
Navigate to Super Admin → Users
Click Add User
Fill in details:
- Name, Email, Password
- Organization: Select customer org
- User Type: Organization Admin
Click Create
Via CLI:
`bash
php admin/add_user.php \
--org-id=1 \
--name="John Doe" \
--email="john@acme.com" \
--type="org_admin" \
--password="temp_password_123"
`
---
Step 4: Enable Multi-Tenant Mode (Optional)
When ready to enable isolated databases:
Edit includes/config.php:
`php
define('TENANT_DB_MIGRATION', true);
`
Test thoroughly before enabling globally!
---
Customer Management
Viewing Organizations
Web UI:
- Super Admin → Dashboard - Overview of all organizations
- Super Admin → Organizations - Detailed list
CLI:
`bash php admin/list_organizations.php `
---
Switching to Customer View
As super admin, you can view any customer's data:
Navigate to Super Admin → Organizations
Click View on any organization
You're now viewing as that organization
Click Exit Organization View to return
---
Managing Subscriptions
Update subscription:
`bash
php admin/update_subscription.php \
--org-id=1 \
--plan="enterprise" \
--status="active" \
--max-users=100
`
Subscription Plans:
- Trial - 30 days, limited features
- Starter - Up to 10 users
- Professional - Up to 50 users
- Enterprise - Unlimited users, all features
---
Data Migration
If migrating from shared DB to tenant DB:
`bash
1. Dry run (test)
php admin/migrate_org_data.php --org-id=1 --dry-run
2. Actual migration
php admin/migrate_org_data.php --org-id=1
3. Verify
php admin/verify_migration.php --org-id=1
4. Delete from shared DB (optional)
php admin/migrate_org_data.php --org-id=1 --delete-after
`
---
Monitoring & Maintenance
Health Checks
Test all tenant connections:
`bash
php tenant-db-setup/test_connection.php --all-orgs
`
Test specific organization:
`bash
php tenant-db-setup/test_connection.php --org-id=1 --verbose
`
---
Backup Procedures
Central SaaS Database:
`bash
mysqldump -u veritylayer -p veritylayer_saas > backup_central_$(date +%Y%m%d).sql
`
Tenant Databases:
`bash
Backup all tenant databases
php admin/backup_all_tenants.php --output-dir=/backups/
`
Restore:
`bash
mysql -u veritylayer -p veritylayer_saas < backup_central_20260104.sql
`
---
Log Monitoring
Application Logs:
logs/application.log - General application logs
logs/tenant-db-setup.log - Tenant provisioning logs
logs/error.log - PHP errors
Database Audit:
`sql SELECT * FROM org_db_connections_audit WHERE created_at > DATE_SUB(NOW(), INTERVAL 24 HOUR) ORDER BY created_at DESC; `
---
Troubleshooting
Common Issues
1. Tenant Connection Fails
Check:
`bash
php tenant-db-setup/test_connection.php --org-id=1 --verbose
`
Possible causes:
- Incorrect credentials
- Firewall blocking connection
- Database not created
- Encryption key mismatch
Fix:
`bash
Re-register connection
php tenant-db-setup/setup_wizard.php --org-id=1
`
---
2. Login Issues
Reset user password:
`bash
php admin/reset_password.php --email="user@example.com"
`
Check user status:
`sql
SELECT * FROM users WHERE email = 'user@example.com';
`
---
3. Performance Issues
Check connection pool:
`sql
SELECT org_id, connection_pool_size, health_status
FROM org_db_connections;
`
Increase pool size:
`sql
UPDATE org_db_connections
SET connection_pool_size = 20
WHERE org_id = 1;
`
---
Support & Updates
Getting Support
Documentation:
- Technical Documentation:
/docs/
API Documentation: /docs/API.md
Migration Guide: /admin/MIGRATION_GUIDE.md
Contact:
- Email: support@veritylayer.com
- Portal: https://support.veritylayer.com
---
Applying Updates
`bash
1. Backup everything
php admin/backup_all.php
2. Download update
wget https://updates.veritylayer.com/v1.1.0.zip
3. Extract (preserves config)
unzip -o v1.1.0.zip
4. Run migrations
php database/migrate.php
5. Clear cache
php admin/clear_cache.php
6. Test
php admin/health_check.php
`
---
Security Best Practices
1. Encryption Key Management
Never commit to version control:
`bash
Add to .gitignore
echo "includes/config.php" >> .gitignore
`
Store securely:
- Use environment variables
- Use secrets management (AWS Secrets Manager, Azure Key Vault)
- Rotate keys periodically
---
2. Database Security
Use strong passwords:
`bash
Generate secure password
openssl rand -base64 32
`
Limit privileges:
`sql
-- Tenant DB users should only access their database
GRANT ALL PRIVILEGES ON org_1_db.* TO 'org_1_user'@'%';
-- Do NOT grant access to other databases
`
---
3. SSL/TLS
Enable HTTPS:
`bash
Install Let's Encrypt
certbot --apache -d veritylayer.yourdomain.com
`
Force HTTPS:
`apache
In .htaccess
RewriteEngine On
RewriteCond %{HTTPS} off
RewriteRule ^(.*)$ https://%{HTTP_HOST}%{REQUEST_URI} [L,R=301]
``
---
4. Regular Updates
Keep updated:- PHP version
- MySQL version
- VerityLayer platform
- Dependencies
- Subscribe to security notifications
- Apply critical patches immediately
Pricing & Licensing
Partner Pricing
Contact us for partner pricing:- Volume discounts available
- White-label options
- Custom deployment support
Customer Licensing
Per-organization pricing:
- Trial: Free for 30 days
- Starter: $99/month (up to 10 users)
- Professional: $299/month (up to 50 users)
- Enterprise: Custom pricing (unlimited users)