Skip to content

feat: update auth and user management#40

Merged
prudentbird merged 8 commits intodevfrom
feat/auth-overhaul
Oct 3, 2025
Merged

feat: update auth and user management#40
prudentbird merged 8 commits intodevfrom
feat/auth-overhaul

Conversation

@prudentbird
Copy link
Copy Markdown
Member

@prudentbird prudentbird commented Oct 3, 2025

Description

This PR updates the user status management system and introduces a verification process for improved user lifecycle handling:

  • Refactored user status logic: Replaced existing active/inactive statuses with verified/unverified.
  • Database migration: Added a migration to update user status fields and introduce a deactivatedAt timestamp for better tracking.
  • User verification process: Implemented functionality in the user service to allow admins to mark users as verified.
  • Service and component updates: Updated affected components and services to align with the new user status model and ensure proper activation/deactivation handling.
  • New mutation decorator: Added a decorator for consistent handling of mutation endpoints across controllers.

Type of Change

  • feat: New feature
  • refactor: Code refactoring

How Has This Been Tested?

  • Unit tests
  • Manual tests

Test Evidence

image

Checklist

  • My code follows the project's coding style
  • I have made corresponding changes to the documentation
  • My changes generate no new warnings
  • I have added tests that prove my fix is effective or that my feature works
  • New and existing unit tests pass locally with my changes
  • I have included a screenshot showing all tests passing

Additional Notes

These changes provide a more robust and flexible user management system by introducing verification workflows and deactivation tracking, while ensuring consistency through a new mutation decorator.

…rocess

- Refactored user status handling to replace 'active' and 'inactive' with 'verified' and 'unverified'.
- Added a new migration to update user status and introduce a 'deactivatedAt' timestamp.
- Implemented user verification functionality in the user service, allowing users to be marked as verified by admins.
- Updated various components and services to reflect the new user status logic and ensure proper handling of user activation and deactivation.
- Introduced a new mutation decorator for handling mutation endpoints across controllers.
…sed tests

- Renamed the method `dgetDashboardData` to `getDashboardData` for clarity and consistency.
- Removed commented-out test cases related to dashboard data retrieval to improve code maintainability and readability.
@prudentbird prudentbird self-assigned this Oct 3, 2025
@claude
Copy link
Copy Markdown

claude bot commented Oct 3, 2025

Claude finished @prudentbird's task —— View job


Code Review for PR #40: feat: update auth and user management

Review Progress:

  • Analyze database migration for user status changes
  • Review new mutation decorator implementation
  • Examine auth guard security updates
  • Check user service refactoring
  • Evaluate controller updates
  • Assess test coverage and quality
  • Review for potential bugs and security issues
  • Provide final recommendations

Overall Assessment

This PR introduces a well-thought-out user verification system with good separation of concerns. The migration from active/inactive to verified/unverified status provides clearer semantics for user lifecycle management.

✅ Strengths

1. Robust Database Migration

  • Comprehensive migration with proper error handling and logging
  • Safe column type transition using temporary columns
  • Includes rollback functionality in the down() method
  • Good data preservation during enum transition

2. Security Architecture

  • Smart verification enforcement: The @Mutation decorator pattern effectively prevents unverified users from performing data-changing operations while allowing read access
  • Proper role-based access controls: Admin/Super Admin restrictions for verification operations
  • Auth guard improvements: Enhanced with deactivation checks and verification-based mutation blocking

3. Clean Code Organization

  • Clear separation between read and write operations
  • Consistent use of the mutation decorator across controllers
  • Good error handling patterns with detailed error messages

4. Comprehensive Test Coverage

  • Auth guard tests cover all new verification scenarios
  • Good mock setup and edge case coverage
  • Tests for both verified and unverified user flows

⚠️ Areas for Improvement

1. Database Migration Concerns

// In migration file lines 53-61
await queryRunner.query(`
  UPDATE "users" 
  SET "status_new" = CASE 
    WHEN "status" = 'active' THEN 'verified'::user_status_new
    ELSE 'unverified'::user_status_new
  END
`);

Issue: This migration assumes only 'active' and 'inactive' values exist. If there are any other status values, they'll all become 'unverified'.
Recommendation: Add validation or explicit handling for unexpected status values.

2. Potential Race Condition in User Service

// In user.service.ts lines 393-403
async verifyUser(id: string, verifiedBy: string) {
  const [userError, user] = await trySafe(() => this.getUserById(id));
  const [verifiedByError, verifiedByUser] = await trySafe(() =>
    this.getUserById(verifiedBy),
  );
  // ... validation logic
  if (user.status === UserStatus.VERIFIED) {
    throw new CustomHttpException(/*...*/);
  }
}

Issue: No database-level constraint prevents concurrent verification attempts.
Recommendation: Consider adding database constraints or optimistic locking to prevent race conditions.

3. Missing Input Validation

  • No validation for user ID formats in service methods
  • Missing null checks for some parameters in mutation operations

4. Auth Guard Type Safety

// In auth.guard.ts line 64
this.userService.getUserById(verifyResult.request.user?.sub as string)

Issue: Type assertion without proper validation could cause runtime errors.
Recommendation: Add runtime validation before the cast.

🐛 Potential Bugs

1. Undefined Reference in Reactivate User

// In user.service.ts line 369
updatePayload: { deactivatedAt: undefined }

Issue: Setting undefined may not properly clear the database field depending on TypeORM configuration.
Recommendation: Use null instead of undefined for database fields.

2. Missing Transaction Support

Several user operations set useTransaction: false but could benefit from transactional safety, especially the verification process which could involve multiple related updates.

🚀 Performance Considerations

1. N+1 Query Pattern

The user service methods that fetch multiple users (like in admin operations) could lead to N+1 queries if not properly optimized with relations.

2. Database Index Recommendations

  • Consider adding index on users.status for efficient filtering
  • Index on users.deactivatedAt for active user queries

🔒 Security Assessment

✅ Security Strengths:

  • Proper role-based authorization checks
  • Good separation of verification logic
  • Protection against unverified users performing mutations

⚠️ Minor Security Concerns:

  • Error messages might be too detailed and could leak information about user existence
  • Consider rate limiting on verification attempts

📋 Final Recommendations

High Priority:

  1. Fix undefined vs null issue in deactivation logic
  2. Add input validation for user IDs
  3. Improve type safety in auth guard

Medium Priority:

  1. Add database constraints for user status transitions
  2. Consider transaction usage for complex operations
  3. Review error message verbosity for security implications

Low Priority:

  1. Add database indexes for performance
  2. Consider adding audit logging for verification actions

Test Coverage Assessment

The test coverage is good, particularly for the auth guard functionality. The tests cover:

  • Public route handling
  • Token validation scenarios
  • User verification status checks
  • Deactivation logic
  • Error handling paths

Conclusion

This is a solid implementation that significantly improves the user management system. The verification workflow is well-designed and the security model is appropriate. The main concerns are around edge cases and type safety rather than fundamental architectural issues.

Recommendation: Approve with minor fixes - Address the undefined/null issue and type safety concerns before merging.

- Changed the `deactivatedAt` property in the user service from `undefined` to `null` to better represent the absence of a deactivation date.
- Updated the user entity and interface to allow `deactivatedAt` to be explicitly `null`, improving type safety and clarity in user status management.
@chunnodu
Copy link
Copy Markdown
Contributor

chunnodu commented Oct 3, 2025

Approved, see recommendations in the comment above @prudentbird

- Introduced a new helper function `isValidUUID` for validating UUID v4 format.
- Updated the `AuthGuard` to validate the user ID extracted from the token.
- Enhanced the `UserService` by adding UUID validation for user-related operations, ensuring that invalid UUIDs are caught early and handled appropriately.
- Improved the update method in the AbstractModelAction class to return null if no records were affected, ensuring better handling of update operations.
- Updated the UserService to include additional validation for UUIDs and refined error handling during user verification, ensuring that already verified users are appropriately managed.
- Cleaned up unnecessary whitespace in the UserService for improved code readability.
- Introduced a new migration to create indexes on the `users` table for the `status` and `deactivated_at` columns, as well as a composite index on both columns.
- Updated the `User` entity to specify the `deactivatedAt` and `resetPasswordExpires` columns as timestamps for better data handling.
- Enhanced the `UserService` to include additional relations in user record options for improved data retrieval.
@claude
Copy link
Copy Markdown

claude bot commented Oct 3, 2025

Claude finished @prudentbird's task —— View job


Code Review for PR #40: feat: update auth and user management

Review Progress:

  • Read and analyze changed files
  • Review database migration implementation
  • Examine mutation decorator and auth guard changes
  • Check user service and controller updates
  • Analyze test coverage and quality
  • Identify potential bugs and security issues
  • Compare against previous review recommendations
  • Provide final feedback and recommendations

Executive Summary

This PR introduces significant improvements to the user management system with a cleaner verification workflow. The implementation is well-structured and secure, with excellent progress since the previous review. Most of the previously identified issues have been addressed effectively.

✅ Key Improvements & Strengths

1. Excellent Migration Implementation

  • Robust error handling: Each migration step has proper try-catch blocks with detailed logging
  • Safe column transitions: Uses temporary columns to avoid data loss during enum changes
  • Complete rollback support: The down() method properly reverses all changes
  • Performance optimization: Added strategic database indexes for commonly queried fields

2. Smart Security Architecture

The @Mutation decorator pattern is brilliantly designed:

  • Unverified users can read data but cannot perform mutations
  • Clear separation between read and write operations
  • Enforced at the guard level for consistent application

3. Robust Validation System

The new validation helper (validation.helper.ts:26-36) provides:

  • Proper UUID v4 validation with regex
  • Type-safe validation functions
  • Consistent error handling across the application

4. Comprehensive Test Coverage

The auth guard tests cover all critical scenarios:

  • Public route handling ✅
  • Token validation ✅
  • User verification status checks ✅
  • Deactivation logic ✅
  • Mutation blocking for unverified users ✅

⚠️ Issues Identified & Recommendations

1. Critical Fix Needed - Null vs Undefined

File: user.service.ts:386

updatePayload: { deactivatedAt: null }  // ✅ Good - Fixed from undefined

Status: ✅ RESOLVED - This was properly fixed from the previous review

2. Minor Security Concern - User Existence Disclosure

File: user.service.ts:418-423

if (userError || verifiedByError) {
  throw new CustomHttpException(
    SYS_MSG.RESOURCE_NOT_FOUND('User'),
    HttpStatus.NOT_FOUND,
  );
}

Issue: Error responses could potentially leak information about user existence
Recommendation: Consider using more generic error messages for security

3. Race Condition in Verification

File: user.service.ts:437-446

identifierOptions: {
  id,
  status: UserStatus.UNVERIFIED, // ✅ Good - Added status check
},

Status: ✅ IMPROVED - The verification now includes status in identifier, reducing race condition risk

4. Performance Optimization Added

File: 1759503641489-AddUserIndexes.ts:38-40

CREATE INDEX IF NOT EXISTS "idx_users_status_deactivated_at" 
ON "users" ("status", "deactivated_at")

Status: ✅ EXCELLENT - Added strategic indexes for optimal query performance

🔍 Code Quality Assessment

Database Layer

  • Migration quality: Excellent with proper error handling and rollback
  • Index strategy: Well-designed composite indexes for common query patterns
  • Data integrity: Safe enum transitions with temporary columns

Service Layer

  • Error handling: Consistent use of trySafe pattern
  • Validation: Proper UUID validation throughout
  • Business logic: Clean separation of concerns

Security Layer

  • Auth guard: Robust implementation with proper status checks
  • Authorization: Proper role-based access controls
  • Input validation: UUID validation prevents injection attacks

Testing

  • Coverage: Comprehensive test scenarios
  • Mock quality: Well-structured mocks with proper typing
  • Edge cases: Good coverage of error conditions

🚀 Performance Considerations

✅ Optimizations Added:

  1. Database indexes on frequently queried columns (status, deactivatedAt)
  2. Composite index for common filter combinations
  3. Efficient validation with compiled regex patterns

💡 Additional Suggestions:

  1. Consider adding index on users.role for admin queries
  2. Monitor query performance for user listing with multiple filters

🔒 Security Assessment

✅ Security Strengths:

  • Proper authorization: Role-based controls for verification operations
  • Input validation: UUID validation prevents malformed requests
  • Status enforcement: Mutation blocking for unverified users
  • Audit trail: deactivatedAt tracking for accountability

⚠️ Minor Security Notes:

  • Error messages could be more generic to prevent user enumeration
  • Consider rate limiting on verification attempts (application-level)

📊 Comparison with Previous Review

Issue Previous Status Current Status
Null vs undefined ❌ Problem ✅ Fixed
Race conditions ⚠️ Concern ✅ Improved
Type safety ⚠️ Concern ✅ Enhanced
Performance ⚠️ Missing indexes ✅ Optimized
Test coverage ✅ Good ✅ Excellent

📋 Final Recommendations

Must Fix (Blocker):

None - all critical issues have been resolved

Should Fix (Minor):

  1. Security: Consider more generic error messages for user lookup failures
  2. Consistency: Add validation for edge cases in batch operations

Nice to Have:

  1. Performance: Monitor and potentially add index on users.role
  2. Observability: Consider adding structured logging for verification events
  3. Documentation: Add inline documentation for the verification workflow

✅ Conclusion

This is a high-quality implementation that significantly improves the user management system. The verification workflow is well-designed, the security model is sound, and the database changes are robust. All major concerns from the previous review have been addressed.

Recommendation: ✅ APPROVE - This PR is ready to merge. The implementation demonstrates excellent software engineering practices with proper error handling, comprehensive testing, and thoughtful security considerations.

The new verification system provides a solid foundation for user lifecycle management while maintaining backwards compatibility and data integrity.


…Service query options

- Replaced hardcoded user IDs with UUIDs in AuthGuard tests to improve consistency and accuracy in token validation.
- Enhanced UserService query options by adding relations for assigned state, local government, phase, and district to improve data retrieval capabilities.
@claude
Copy link
Copy Markdown

claude bot commented Oct 3, 2025

Claude finished @prudentbird's task —— View job


Code Review for PR #40: feat: update auth and user management

Review Progress:

  • Analyze database migration implementation
  • Review new mutation decorator and auth guard changes
  • Examine user service and controller updates
  • Check test coverage and quality
  • Identify potential bugs and security issues
  • Provide final recommendations and feedback

Executive Summary

This PR introduces a well-architected user verification system that significantly improves the user management capabilities. The implementation demonstrates excellent software engineering practices with robust error handling, comprehensive testing, and thoughtful security considerations.

✅ Key Strengths

1. Excellent Database Migration Strategy

  • Safe enum transitions: Uses temporary columns to prevent data loss during type changes
  • Comprehensive error handling: Each migration step includes proper logging and error recovery
  • Complete rollback support: Both migrations have well-implemented down() methods
  • Performance optimization: Strategic database indexes for commonly queried fields

2. Smart Security Architecture

The @Mutation decorator pattern is brilliantly designed:

  • Unverified users can read data but cannot perform mutations
  • Clear separation between read and write operations
  • Enforced at the guard level for consistent application across all controllers

3. Robust Auth Guard Implementation

  • Comprehensive validation: Token extraction, JWT verification, UUID validation
  • Deactivation checks: Prevents deactivated users from accessing any protected endpoints
  • Status-based access control: Mutation blocking for unverified users
  • Error handling: Proper exception types with detailed error messages

4. Well-Implemented Verification Logic

  • Role-based authorization: Only Admin/Super Admin can verify users
  • Race condition prevention: Uses compound identifiers (id + status) in update operations
  • Proper validation: UUID validation throughout the service layer
  • Clear error messaging: Distinguishes between already verified vs. operation failures

5. Comprehensive Test Coverage

The auth guard tests cover all critical scenarios with high-quality mocks and realistic test cases.

⚠️ Areas for Improvement

1. Transaction Usage Patterns

Issue: Many operations use useTransaction: false but could benefit from transactional safety:

// user.service.ts:444, 388, 317, etc.
transactionOptions: { useTransaction: false }

Recommendation: Consider enabling transactions for complex operations like user verification, which could involve multiple related updates.

2. Error Message Information Disclosure

Location: user.service.ts:418-423

if (userError || verifiedByError) {
  throw new CustomHttpException(
    SYS_MSG.RESOURCE_OPERATION_FAILED('User Verification'),
    HttpStatus.BAD_REQUEST,
  );
}

Issue: Error responses could potentially leak information about user existence.
Recommendation: Consider using more generic error messages or implementing rate limiting on verification attempts.

3. Validation Helper File Corruption

Location: validation.helper.ts:39-42

// Corrupted comment block with incomplete implementation details

Issue: The file contains corrupted comments that should be cleaned up.
Recommendation: Remove the malformed comment block for code clarity.

🔒 Security Assessment

✅ Security Strengths:

  • Proper authorization: Role-based controls for sensitive operations
  • Input validation: Comprehensive UUID and parameter validation
  • Status enforcement: Mutation blocking prevents unauthorized actions
  • Audit trail: deactivatedAt timestamp for accountability
  • Password security: Proper bcrypt hashing in auth service

🟡 Minor Security Considerations:

  • Information disclosure: Error messages could be more generic
  • Rate limiting: Consider adding application-level rate limiting for verification attempts
  • Transaction safety: Some sensitive operations could benefit from database transactions

🚀 Performance Considerations

✅ Optimizations Added:

  1. Database indexes: Strategic indexes on status, deactivatedAt, and composite indexes
  2. Efficient queries: Proper use of identifiers to minimize database hits
  3. Validation optimization: Compiled regex patterns for UUID validation

💡 Additional Suggestions:

  1. Consider adding index on users.role for admin operations
  2. Monitor query performance for user listing with complex filters

🐛 Potential Issues Found

1. Minor - Transaction Consistency (Low Priority)

Several user operations disable transactions but involve related data that could benefit from atomic operations.

2. Minor - Code Cleanliness (Low Priority)

Validation helper file contains corrupted comments that should be cleaned up.

📋 Final Recommendations

High Priority ✅

All critical issues have been addressed in this implementation. No blocking issues found.

Medium Priority (Nice to Have):

  1. Security: Consider more generic error messages for user lookup operations
  2. Transactions: Enable transactions for complex multi-step operations
  3. Code quality: Clean up corrupted comments in validation helper

Low Priority:

  1. Performance: Add monitoring for user query performance
  2. Documentation: Consider adding inline documentation for verification workflow

✅ Conclusion

This is a high-quality implementation that significantly improves the user management system. The verification workflow is well-designed, the security model is sound, and the database changes are robust.

Recommendation: ✅ APPROVE - This PR demonstrates excellent software engineering practices and is ready for merge.

Key highlights:

  • ✅ Robust database migrations with proper rollback support
  • ✅ Smart security architecture with mutation-based access control
  • ✅ Comprehensive error handling and validation
  • ✅ Excellent test coverage with realistic scenarios
  • ✅ Performance optimizations with strategic database indexes

The new verification system provides a solid foundation for user lifecycle management while maintaining backwards compatibility and data integrity.


- Removed unnecessary commented-out code in the validation helper to enhance code clarity and maintainability.
@claude
Copy link
Copy Markdown

claude bot commented Oct 3, 2025

Claude finished @prudentbird's task —— View job


Code Review for PR #40: feat: update auth and user management

Review Progress:

  • Analyze database migration implementation
  • Review new mutation decorator and auth guard changes
  • Examine user service and controller updates
  • Check test coverage and quality
  • Identify potential bugs and security issues
  • Provide final recommendations and feedback

Executive Summary

This PR introduces a well-architected user verification system that significantly improves the user management capabilities. The implementation demonstrates excellent software engineering practices with robust error handling, comprehensive testing, and thoughtful security considerations.

✅ Key Strengths

1. Excellent Database Migration Strategy

  • Safe enum transitions: Uses temporary columns to prevent data loss during type changes (UpdateUserStatusAndAddDeactivatedAt1759493969854:39-94)
  • Comprehensive error handling: Each migration step includes proper logging and error recovery
  • Complete rollback support: Both migrations have well-implemented down() methods
  • Performance optimization: Strategic database indexes for commonly queried fields (AddUserIndexes1759503641489:10-40)

2. Smart Security Architecture

The @Mutation decorator pattern is brilliantly designed:

  • Unverified users can read data but cannot perform mutations (auth.guard.ts:95-100)
  • Clear separation between read and write operations
  • Enforced at the guard level for consistent application across all controllers

3. Robust Auth Guard Implementation

  • Comprehensive validation: Token extraction, JWT verification, UUID validation (auth.guard.ts:42-70)
  • Deactivation checks: Prevents deactivated users from accessing any protected endpoints (auth.guard.ts:83-88)
  • Status-based access control: Mutation blocking for unverified users
  • Error handling: Proper exception types with detailed error messages

4. Well-Implemented Verification Logic

  • Role-based authorization: Only Admin/Super Admin can verify users (user.service.ts:427-435)
  • Race condition prevention: Uses compound identifiers (id + status) in update operations (user.service.ts:437-446)
  • Proper validation: UUID validation throughout the service layer (validation.helper.ts:26-36)
  • Clear error messaging: Distinguishes between already verified vs. operation failures

5. Comprehensive Test Coverage

The auth guard tests cover all critical scenarios with high-quality mocks and realistic test cases:

  • Public route handling (auth.guard.spec.ts:102-109)
  • Token validation (auth.guard.spec.ts:126-146)
  • User verification status checks (auth.guard.spec.ts:178-226)
  • Deactivation logic (auth.guard.spec.ts:148-176)

⚠️ Areas for Improvement

1. Transaction Usage Patterns

Issue: Many operations use useTransaction: false but could benefit from transactional safety:

// user.service.ts:444, 388, 317, etc.
transactionOptions: { useTransaction: false }

Recommendation: Consider enabling transactions for complex operations like user verification, which could involve multiple related updates.

2. Error Message Information Disclosure

Location: user.service.ts:418-423

if (userError || verifiedByError) {
  throw new CustomHttpException(
    SYS_MSG.RESOURCE_OPERATION_FAILED('User Verification'),
    HttpStatus.BAD_REQUEST,
  );
}

Issue: Error responses could potentially leak information about user existence.
Recommendation: Consider using more generic error messages or implementing rate limiting on verification attempts.

3. Validation Helper File Quality

Location: validation.helper.ts:39-66
The validation helper implementation is solid with proper UUID validation and comprehensive helper functions.

🔒 Security Assessment

✅ Security Strengths:

  • Proper authorization: Role-based controls for sensitive operations
  • Input validation: Comprehensive UUID and parameter validation (validation.helper.ts:16-36)
  • Status enforcement: Mutation blocking prevents unauthorized actions
  • Audit trail: deactivatedAt timestamp for accountability (user.entity.ts:33-34)
  • Password security: Proper bcrypt hashing in auth service

🟡 Minor Security Considerations:

  • Information disclosure: Error messages could be more generic
  • Rate limiting: Consider adding application-level rate limiting for verification attempts
  • Transaction safety: Some sensitive operations could benefit from database transactions

🚀 Performance Considerations

✅ Optimizations Added:

  1. Database indexes: Strategic indexes on status, deactivatedAt, and composite indexes
  2. Efficient queries: Proper use of identifiers to minimize database hits
  3. Validation optimization: Compiled regex patterns for UUID validation

💡 Additional Suggestions:

  1. Consider adding index on users.role for admin operations
  2. Monitor query performance for user listing with complex filters

🐛 Potential Issues Found

1. Minor - Transaction Consistency (Low Priority)

Several user operations disable transactions but involve related data that could benefit from atomic operations.

2. Minor - Code Organization (Low Priority)

All controller mutations properly use the @Mutation() decorator for consistent access control.

📋 Final Recommendations

High Priority ✅

All critical issues have been addressed in this implementation. No blocking issues found.

Medium Priority (Nice to Have):

  1. Security: Consider more generic error messages for user lookup operations
  2. Transactions: Enable transactions for complex multi-step operations
  3. Performance: Monitor query performance with new indexes

Low Priority:

  1. Documentation: Consider adding inline documentation for verification workflow
  2. Observability: Add structured logging for verification events

✅ Conclusion

This is a high-quality implementation that significantly improves the user management system. The verification workflow is well-designed, the security model is sound, and the database changes are robust.

Recommendation: ✅ APPROVE - This PR demonstrates excellent software engineering practices and is ready for merge.

Key highlights:

  • ✅ Robust database migrations with proper rollback support
  • ✅ Smart security architecture with mutation-based access control
  • ✅ Comprehensive error handling and validation
  • ✅ Excellent test coverage with realistic scenarios
  • ✅ Performance optimizations with strategic database indexes

The new verification system provides a solid foundation for user lifecycle management while maintaining backwards compatibility and data integrity.


@prudentbird prudentbird merged commit 8d6b200 into dev Oct 3, 2025
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants