Antivirus for Amazon S3
Project description
@cloudcomponents/cdk-s3-antivirus
Antivirus for Amazon S3
Install
TypeScript/JavaScript:
npm i @cloudcomponents/cdk-s3-antivirus
Python:
pip install cloudcomponents.cdk-s3-antivirus
How to use
# Example automatically generated without compilation. See https://github.com/aws/jsii/issues/826
from aws_cdk.aws_lambda_destinations import SnsDestination
from aws_cdk.aws_s3 import Bucket
from aws_cdk.aws_sns import Topic
from aws_cdk.aws_sns_subscriptions import EmailSubscription
from aws_cdk.core import Construct, RemovalPolicy, Stack, StackProps
from cloudcomponents.cdk_s3_antivirus import Scanner
class S3AntivirusStack(Stack):
def __init__(self, scope, id, *, description=None, env=None, stackName=None, tags=None, synthesizer=None, terminationProtection=None, analyticsReporting=None):
super().__init__(scope, id, description=description, env=env, stackName=stackName, tags=tags, synthesizer=synthesizer, terminationProtection=terminationProtection, analyticsReporting=analyticsReporting)
bucket = Bucket(self, "Bucket",
auto_delete_objects=True,
removal_policy=RemovalPolicy.DESTROY
)
topic = Topic(self, "Topic")
topic.add_subscription(EmailSubscription(process.env.DEVSECOPS_TEAM_EMAIL))
scanner = Scanner(self, "Scanner",
on_result=SnsDestination(topic),
on_error=SnsDestination(topic)
)
scanner.add_source_bucket(bucket)
API Reference
See API.md.
Example
See more complete examples.
License
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for cloudcomponents.cdk-s3-antivirus-1.8.0.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 038ac9c7952bd791694d7355cb8d34eb24f37346658ca79335004d315470124e |
|
MD5 | 6cc065c9c6271a272570d3b6507a3e2c |
|
BLAKE2b-256 | 4d9df75b3124c57a490cc184ed89f7352043a864326de35218a1c773317670a6 |
Close
Hashes for cloudcomponents.cdk_s3_antivirus-1.8.0-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 37026b8a584da063134c458db3177b44b572e7b00f576fb6f0bedbd398a414e9 |
|
MD5 | 9a2beff12520d0cf8cff6a3867b12eff |
|
BLAKE2b-256 | 3e8e4a15e9c5d4879c0bb1990e8e6ecb3e4095898bdb11b83b41cfe86327501c |