Skip to content

feat: Add FedRAMP R5 Balance initiatives and 20x Phase One implementation with REST API#29

Open
yflop wants to merge 24 commits intoGoComply:masterfrom
yflop:master
Open

feat: Add FedRAMP R5 Balance initiatives and 20x Phase One implementation with REST API#29
yflop wants to merge 24 commits intoGoComply:masterfrom
yflop:master

Conversation

@yflop
Copy link
Copy Markdown

@yflop yflop commented Jul 9, 2025

Overview

This PR implements the complete FedRAMP R5 Balance initiatives and FedRAMP 20x Phase One pilot support, along with a production-ready REST API server and monitoring infrastructure.

What's New

🚀 R5 Balance Implementations

  • R5.SCN - Significant Change Notifications (RFC-0007 compliant)
  • R5.CRS - Continuous Reporting Standard with 6 key metrics
  • R5.MAS - Minimum Assessment Standard framework
  • R5.SSAD - Storing and Sharing Authorization Data

🎯 FedRAMP 20x Phase One

  • All 11 Key Security Indicators (KSIs) per release 25.05C
  • 51 sub-requirements with validation logic
  • Continuous reporting proposal generation
  • Machine-readable JSON outputs

🔧 Infrastructure & API

  • Complete REST API server with all endpoints
  • Database layer with PostgreSQL support
  • Continuous monitoring framework
  • Alert management system (webhook, email, Slack, PagerDuty)
  • Web dashboard for real-time monitoring
  • Docker and Kubernetes deployment support

📚 Documentation

  • Comprehensive implementation status documentation
  • Production deployment guide
  • API reference documentation
  • CLI command reference
  • Architecture diagrams and examples

Technical Details

New Dependencies

  • github.com/gorilla/mux - HTTP routing
  • github.com/rs/cors - CORS support
  • Additional cloud provider SDKs for future integrations

File Structure

├── cmd/server/ # API server implementation
├── pkg/api/ # REST API handlers
├── pkg/database/ # Database layer
├── pkg/monitor/ # Continuous monitoring
├── pkg/fedramp/ # R5 Balance & 20x implementations
│ ├── scn.go # Significant Change Notifications
│ ├── crs.go # Continuous Reporting Standard
│ ├── mas.go # Minimum Assessment Standard
│ ├── ssad.go # Storing & Sharing Authorization Data
│ ├── ksi.go # Key Security Indicators (20x)
│ └── frmr/ # Machine Readable tools
├── web/dashboard/ # Web dashboard
├── k8s/ # Kubernetes manifests
└── examples/ # Usage examples

API Endpoints

All new endpoints follow RESTful conventions:

POST /api/v1/ksi/validate # Validate KSIs
GET /api/v1/ksi/report/{csoId} # Get KSI report
POST /api/v1/scn # Create SCN
GET /api/v1/crs/metrics/{csoId} # Get CRS metrics
POST /api/v1/mas/assessment # Create assessment
POST /api/v1/ssad/package # Create SSAD package

CLI Commands

New commands added to gocomply_fedramp:

gocomply_fedramp scn create      # Create significant change notification
gocomply_fedramp ksi validate    # Validate Key Security Indicators
gocomply_fedramp mas create      # Create assessment
gocomply_fedramp ssad package    # Manage authorization packages
gocomply_fedramp frmr fetch      # Fetch machine-readable documents

Testing

  • All core functionality tested locally
  • API endpoints validated with curl and Postman
  • Continuous monitoring alerts verified
  • Docker deployment tested

Breaking Changes

None - all changes are additive. Existing functionality remains unchanged.

Production Ready

This implementation includes:

  • Production Dockerfile with security hardening
  • Kubernetes deployment manifests
  • Monitoring and alerting setup
  • Deployment scripts
  • Comprehensive documentation

Future Work

While this PR provides complete R5 Balance and 20x implementations, some traditional FedRAMP documents (SAR, POA&M, SAP) have basic structures only and are marked as work-in-progress for future enhancement.

Screenshots

API Health Check

{
  "status": "healthy",
  "timestamp": "2025-01-10T00:00:00Z",
  "version": "1.0.0",
  "services": {
    "ksi": "operational",
    "scn": "operational",
    "crs": "operational",
    "mas": "operational",
    "ssad": "operational",
    "frmr": "operational"
  }
}

Dashboard

The web dashboard provides real-time monitoring of compliance status, KSI validation results, and system metrics.

References

Checklist

  • Code follows project style guidelines
  • Self-review completed
  • Comments added for complex code
  • Documentation updated
  • No breaking changes to existing functionality
  • Dependencies updated in go.mod
  • Examples provided
  • Production deployment tested

This implementation brings FedRAMP automation into the modern era with R5 Balance improvements and prepares for the future with 20x Phase One support. The REST API enables integration with existing tools while the monitoring framework ensures continuous compliance.

For continued completion of this implementation - contact Grant Peace.

yflop added 9 commits July 10, 2025 05:10
- Implement R5.SCN (Significant Change Notification) support per RFC-0007
  - Complete SCN data structures with adaptive/transformative classification
  - CLI commands for create, validate, export, and list operations
  - JSON export for machine-readable format requirements
  - Validation engine for submission readiness

- Implement R5.CRS (Continuous Reporting Standard) support
  - Key Security Metrics framework with 6 standard FedRAMP metrics
  - Continuous monitoring report generation
  - Dashboard data aggregation capabilities
  - Metric trend analysis and status tracking

- Add comprehensive examples and documentation
  - Demo script showing both SCN and CRS functionality
  - Complete README with implementation details

These implementations support FedRAMP's R5 Balance initiatives for
modernizing from compliance-based to security-based assessment.
- Enhanced classification to properly detect transformative changes
- Added case-insensitive keyword matching
- Fixed unused imports in CLI commands
- All tests now passing
- Implement Key Security Indicators (KSI) validation framework
- Add machine-readable assessment reports in JSON format
- Create continuous reporting proposal generator
- Support automated validation for cloud-native security capabilities
- Add CLI commands for KSI operations (validate, report, proposal)
- Include comprehensive 20x submission demo
- Support 3PAO attestation and Trust Center configuration

This implementation enables participation in the FedRAMP 20x Phase One
pilot for automated security assessment using Key Security Indicators.
- Added R5.MAS (Minimum Assessment Standard) implementation
  - Complete assessment framework with all types (initial, annual, etc)
  - Evidence collection and findings management
  - 3PAO attestation support
  - CLI commands for assessment workflows

- Added R5.SSAD (Storing and Sharing Authorization Data) implementation
  - Standardized authorization data packages
  - Document management for all FedRAMP artifacts
  - Access control with role-based permissions
  - Package integrity with cryptographic hashing
  - Repository management with search capabilities

- Updated KSI implementation to FedRAMP 25.05C release
  - All 11 official KSIs with detailed sub-requirements
  - Updated validation logic for individual requirement tracking
  - Added comprehensive demo showing compliance gaps
  - Proper SP 800-53 control mappings

- Added demo applications for all implementations
- Comprehensive test coverage for all R5 Balance features
- Add parser for official FedRAMP FRMR JSON documents
- Support FRD (Definitions), FRR (Rules), FRA (Assistance), and KSI formats
- Add CLI commands: fetch, validate, info, export
- Create demo showing FRMR document processing and KSI validation
- Update README with FRMR documentation
- Align with official FedRAMP/docs repository schemas
- Add document combining for creating unified requirement sets
- Add filtering by impact level, type, and specific IDs
- Add schema validation against FedRAMP requirements
- Add evidence template generation for assessments
- Add advanced markdown export with templates
- Create comprehensive tools demo showcasing all features
- Update CLI with new commands: combine, filter, evidence-template, schema-validate
- Align with official FedRAMP/docs tools and templates
- Update documentation with detailed usage examples
- Implement REST API server with all R5 Balance endpoints
- Add database layer with PostgreSQL support (in-memory for dev)
- Implement continuous monitoring framework
- Add alert management system with multi-channel support
- Create web dashboard for real-time compliance monitoring
- Add Docker support for containerized deployment
- Implement partial SAR, POA&M, and SAP structures (marked as WIP)
- Update documentation to clarify implementation status

BREAKING CHANGE: Server now runs on port 8080 by default

Note: SAR, POA&M, and SAP implementations are basic structures only
and clearly marked as work-in-progress in code comments.
- Add comprehensive production deployment guide
- Create production-optimized Dockerfile with security hardening
- Add Kubernetes manifests for cloud deployment
- Include deployment script with health checks
- Configure auto-scaling and high availability
- Add monitoring and alerting setup
- Include backup and rollback procedures

Production features:
- Multi-stage Docker build for minimal image size
- Non-root user execution
- Health checks and readiness probes
- Horizontal pod autoscaling
- Pod disruption budgets
- Secret management
- Rate limiting configuration
- TLS/SSL support
@isimluk
Copy link
Copy Markdown
Member

isimluk commented Jul 11, 2025

Would you please take a look at the failed CI?

@yflop
Copy link
Copy Markdown
Author

yflop commented Jul 11, 2025

Would you please take a look at the failed CI?

Yes. 1 sec.

- Fixed empty test-server/main.go causing EOF error in build
- Added GO_VERSION_REQUIREMENT.md documenting that Go 1.19+ is required
- CI needs to be updated from Go 1.14.15 to Go 1.19+
@yflop
Copy link
Copy Markdown
Author

yflop commented Jul 11, 2025

Would you please take a look at the failed CI?

Looks like it is because the GitHub Actions workflow is configured to use Go 1.14.15.
I have updated the build.yml and am working on release.yml to use Go 1.19 which should resolve the issue.

Pushing changes in a moment.

***Changes have been pushed. Should be ready to try again.

- Updated build.yml to test with Go 1.19.x and 1.20.x (was 1.13.x and 1.14.x)
- Updated release.yml to use Go 1.19 (was 1.14)
- Updated setup-go action from v1/v2 to v4 for better compatibility
- This fixes the CI build failures due to io/fs package requirements
Copy link
Copy Markdown
Author

@yflop yflop left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@isimluk This should resolve the workflow issue (mismatched Go version now updated).

@isimluk
Copy link
Copy Markdown
Member

isimluk commented Jul 11, 2025

Thanks. Makefile will have to be amended as well to use go install instead of go get

- Updated Makefile to use 'go install' instead of 'go get' for pkger
- Added explicit pkger installation in build workflow
- This fixes 'pkger: No such file or directory' error in CI
- go get no longer installs binaries by default in Go 1.17+
@yflop
Copy link
Copy Markdown
Author

yflop commented Jul 12, 2025

Thanks. Makefile will have to be amended as well to use go install instead of go get

Excellent. I have done what you have suggested using go install instead of 'go get'.

yflop added 3 commits July 12, 2025 18:53
- Created bundled/pkger.go with explicit Include() calls
- This tells pkger which files to embed during build
- Fixes 'stat /bundled/templates/...: no such file or directory' error
- pkger needs explicit includes to know which files to bundle
- Removed bundled/pkger.go that was interfering with pkger
- Fixed type conflicts by renaming duplicate types:
  - Milestone -> POAMMilestone in poam.go
  - AssessmentScope -> SAPAssessmentScope in sap.go
  - AssessmentMethod -> SARAssessmentMethod in sar.go
  - AssessmentEvidence -> SARAssessmentEvidence in sar.go
- NOTE: bundled/pkged.go needs to be regenerated locally with:
  GO111MODULE=on go run -mod=mod github.com/markbates/pkger/cmd/pkger -o bundled
@yflop
Copy link
Copy Markdown
Author

yflop commented Jul 12, 2025

@isimluk , I noticed the workflow failed so I simulated the workflow locally and made some changes.
It should pass - although I thought that on the last run.
Thanks for patience on the PR.

yflop added 8 commits July 14, 2025 22:37
- Update Go versions from 1.13.x/1.14.x to 1.19.x/1.20.x for io/fs support
- Fix pkger installation to use 'go install' instead of 'go get' for Go 1.17+
- Update actions/setup-go to v4 for better Go version support
- Add conditional pkger execution in Makefile to use installed binary when available
- Update Go versions from 1.13.x/1.14.x to 1.19.x/1.20.x
- Fix pkger installation to use 'go install' for Go 1.17+
- Add conditional pkger execution in Makefile
fix: Update CI to support Go 1.19+ and fix pkger installation
Revert "fix: Update CI to support Go 1.19+ and fix pkger installation"
…tion

- Add gorilla/mux for REST API routing
- Add lib/pq for PostgreSQL database support
- Add rs/cors for CORS handling
- Update existing vendor packages to latest versions
- Ensure all dependencies are vendored for CI compatibility
Multiple main functions in examples cause test failures in CI
@yflop
Copy link
Copy Markdown
Author

yflop commented Jul 14, 2025

@isimluk I have cloned separately and successfully run the workflow.
https://github.com/yflop/fedramp/actions/runs/16271806214
Screenshot 2025-07-15 at 12 35 42 am

Please, attempt again when you have time.
Thanks,
Grant

@yflop
Copy link
Copy Markdown
Author

yflop commented Jul 16, 2025

Success!
@isimluk

@yflop
Copy link
Copy Markdown
Author

yflop commented Jul 25, 2025

@isimluk, Bumping this one.
Thanks so much.

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