cdklabs / cdklabs/construct-hub

Add/document ways to secure frontend

Open
#988 5 comments 7 reactions 0 assignees View on GitHub
feature-request
Dominant language
TypeScript
Stars
239
Forks
30
Avg merge
1d 9h
Merged PRs (30d)
11

Description

### Description

If this is already implemented, please forgive me.

After reading the docs and perusing the `construct-hub` source code, I've been unable to find a recommended way to protect the HTML frontend for the webapp served by the CloudFront distribution.

Does a recommended method of doing this exist?

If not, would it be acceptable to directly expose the CloudFront Distribution as a property of the `ConstructHub` construct? My thinking here is that a reference to this CloudFront Distribution resource could be used to gate access to the served webpage using something like the AWS Cognito Hosted UI or simply Basic Auth.

### Use Case

Without the ability to restrict access to the frontend, I believe having a self-hosted construct hub isn't useful to companies. How could an enterprise use a self-hosted ConstructHub if the whole world can see their docs?

If a company doesn't mind their docs being exposed, I imagine they'd use the public instance of Construct Hub.

### Other information

_No response_

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.