sudo oscap xccdf eval --oval-results --profile cis --results-arf /tmp/arf.xml --report /tmp/report.html /usr/share/xml/scap/ssg/content/ssg-rhel8-ds.xml
oscap xccdf generate fix --fix-type ansible --result-id "" /tmp/arf.xml > playbook.yml
| <?xml version="1.0" encoding="utf-8"?> | |
| <unattend xmlns="urn:schemas-microsoft-com:unattend"> | |
| <settings pass="windowsPE"> | |
| <component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | |
| <SetupUILanguage> | |
| <UILanguage>en-US</UILanguage> | |
| </SetupUILanguage> | |
| <InputLocale>en-US</InputLocale> | |
| <SystemLocale>en-US</SystemLocale> | |
| <UILanguage>en-US</UILanguage> |
| <?xml version="1.0" encoding="utf-8"?> | |
| <unattend xmlns="urn:schemas-microsoft-com:unattend"> | |
| <settings pass="windowsPE"> | |
| <component name="Microsoft-Windows-International-Core-WinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | |
| <SetupUILanguage> | |
| <UILanguage>en-US</UILanguage> | |
| </SetupUILanguage> | |
| <InputLocale>en-US</InputLocale> | |
| <SystemLocale>en-US</SystemLocale> | |
| <UILanguage>en-US</UILanguage> |
| $EC2SettingsFile="C:\\Program Files\\Amazon\\Ec2ConfigService\\Settings\\BundleConfig.xml" | |
| $xml = [xml](get-content $EC2SettingsFile) | |
| $xmlElement = $xml.get_DocumentElement() | |
| foreach ($element in $xmlElement.Property) | |
| { | |
| if ($element.Name -eq "AutoSysprep") | |
| { | |
| $element.Value="Yes" | |
| } |
| <?xml version="1.0" encoding="utf-8"?> | |
| <unattend xmlns="urn:schemas-microsoft-com:unattend"> | |
| <settings pass="windowsPE"> | |
| <!-- look for drivers on floppy --> | |
| <component name="Microsoft-Windows-PnpCustomizationsWinPE" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> | |
| <DriverPaths> | |
| <PathAndCredentials wcm:keyValue="1" wcm:action="add"> | |
| <Path>A:\</Path> | |
| </PathAndCredentials> | |
| </DriverPaths> |
| ### Install the required packages: | |
| sudo yum install openscap-scanner scap-security-guide | |
| ### Can we run a report? | |
| sudo oscap xccdf eval --profile xccdf_org.ssgproject.content_profile_ospp --report /tmp/report.html /usr/share/xml/scap/ssg/content/ssg-rhel8-ds.xml | |
| first scan gives “notapplicable” | |
| ### Now do this… | |
| sudo cp /usr/share/openscap/cpe/openscap-cpe-dict.xml /usr/share/openscap/cpe/openscap-cpe-dict.xml.dist |
sudo oscap xccdf eval --oval-results --profile cis --results-arf /tmp/arf.xml --report /tmp/report.html /usr/share/xml/scap/ssg/content/ssg-rhel8-ds.xml
oscap xccdf generate fix --fix-type ansible --result-id "" /tmp/arf.xml > playbook.yml
| resource "aws_budgets_budget" "cloudwatch" { | |
| provider = "aws.billing" | |
| name = "budget-cloudwatch-monthly" | |
| budget_type = "COST" | |
| limit_amount = "1000" | |
| limit_unit = "USD" | |
| time_period_end = "2087-06-15_00:00" | |
| time_period_start = "2017-07-01_00:00" | |
| time_unit = "MONTHLY" |
| AWS Lambda functions and API gateway are often used to create serverless applications. | |
| Function code is written in Go and deployed using Terraform. |
| const WebSocket = require('websocket').w3cwebsocket; | |
| var token = "key-token"; | |
| const socket = new WebSocket('ws://localhost:8000/ws', null, null, { | |
| Authorization: `Bearer ${token}` | |
| }); | |
| socket.onopen = () => { | |
| console.log('WebSocket connection established'); |
| ### LAMBDA | |
| module "lambda_function" { | |
| source = "terraform-aws-modules/lambda/aws" | |
| function_name = "outdoor-activities-generator" | |
| description = "Generates a map containing your outdoor activities" | |
| handler = "main.lambda_handler" | |
| runtime = "python3.11" | |
| timeout = 60 |