<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Security Archives - Rambunct Consulting</title>
	<atom:link href="https://rc.global-exposure.co.uk/category/security/feed/" rel="self" type="application/rss+xml" />
	<link>https://rc.global-exposure.co.uk/category/security/</link>
	<description></description>
	<lastBuildDate>Fri, 16 Oct 2026 12:06:59 +0000</lastBuildDate>
	<language>en-GB</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.1.4</generator>
	<item>
		<title>Using AWS Secrets Manager with Amazon EKS for Secure Secrets Management</title>
		<link>https://rc.global-exposure.co.uk/using-aws-secrets-manager-with-amazon-eks-for-secure-secrets-management/</link>
					<comments>https://rc.global-exposure.co.uk/using-aws-secrets-manager-with-amazon-eks-for-secure-secrets-management/#respond</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Mon, 17 Aug 2026 13:05:13 +0000</pubDate>
				<category><![CDATA[Containers & Kubernetes]]></category>
		<category><![CDATA[Security]]></category>
		<guid isPermaLink="false">https://rc.global-exposure.co.uk/?p=442</guid>

					<description><![CDATA[<p>Managing sensitive credentials like database passwords, API keys, or authentication […]</p>
<p>The post <a href="https://rc.global-exposure.co.uk/using-aws-secrets-manager-with-amazon-eks-for-secure-secrets-management/">Using AWS Secrets Manager with Amazon EKS for Secure Secrets Management</a> appeared first on <a href="https://rc.global-exposure.co.uk">Rambunct Consulting</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Managing sensitive credentials like database passwords, API keys, or authentication tokens in Kubernetes is a critical aspect of application security. By integrating AWS Secrets Manager with Amazon EKS, you can securely store and retrieve secrets for your applications while following best practices for access control and automation.</p>
<p>This blog will guide you through setting up an Amazon EKS cluster, integrating AWS Secrets Manager, and deploying a sample application to demonstrate secure secret retrieval.</p>
<h3><strong>Step 1: Set Up an Amazon EKS Cluster</strong></h3>
<h4><strong>1. Create the EKS Cluster</strong></h4>
<p>Run the following command to create an EKS cluster:</p>
<blockquote>
<p>eksctl create cluster \ –name demo-eks-cluster \ –region us-east-1 \ –nodegroup-name std-workers \ –node-type t3.medium \ –nodes 2 \ –nodes-min 1 \ –nodes-max 3 \ –managed</p>
</blockquote>
<p>This command creates an EKS cluster with a managed node group in the us-east-1 region.</p>
<h4><strong>2. Verify the Cluster</strong></h4>
<p>Ensure the cluster was created successfully:</p>
<blockquote>
<p>eksctl get cluster –region us-east-1</p>
</blockquote>
<h4><strong>3. Update kubeconfig</strong></h4>
<p>Update the kubeconfig file to connect kubectl to your EKS cluster:</p>
<blockquote>
<p>aws eks –region us-east-1 update-kubeconfig –name demo-eks-cluster</p>
</blockquote>
<h4><strong>4. Verify Node Readiness</strong></h4>
<p>Check if the worker nodes are ready:</p>
<blockquote>
<p>kubectl get nodes</p>
</blockquote>
<p>You should see the nodes in the Ready state.</p>
<h3><strong>Step 2: Store Secrets in AWS Secrets Manager</strong></h3>
<h4><strong>1. Create a Secret</strong></h4>
<p>Example: RambunctDatabaseSecret</p>
<h4><strong>2. Copy the Secret ARN</strong></h4>
<p>After saving the secret, copy the <strong>ARN</strong> for use in the IAM role permissions.</p>
<h3><strong>Step 3: Enable IAM Roles for Service Accounts (IRSA)</strong></h3>
<h4><strong>1. Associate OIDC Provider</strong></h4>
<p>Enable IAM Roles for Service Accounts (IRSA) by associating an OIDC provider with your cluster:</p>
<blockquote>
<p>eksctl utils associate-iam-oidc-provider –region us-east-1 –cluster demo-eks-cluster –approve</p>
</blockquote>
<h4><strong>2. Verify OIDC Provider</strong></h4>
<p>Check if the OIDC provider is correctly associated:</p>
<blockquote>
<p>aws eks describe-cluster –name demo-eks-cluster –query “cluster.identity.oidc.issuer” –output text</p>
</blockquote>
<p>The output should resemble:</p>
<blockquote>
<p>https://oidc.eks.us-east-1.amazonaws.com/id/<oidc-id></p>
</blockquote>
<h3><strong>Step 4: Create IAM Role with Secret Access</strong></h3>
<h4><strong>1. Create IAM Policy</strong></h4>
<p>Save the following JSON policy as secrets-access-policy.json:</p>
<blockquote>
<p>{ “Version”: “2012-10-17”, “Statement”: [ { “Effect”: “Allow”, “Action”: [ “secretsmanager:ListSecrets”, “secretsmanager:GetSecretValue” ], “Resource”: [ “arn:aws:secretsmanager:us-east-1:<account-id>:secret:RambunctDatabaseSecret*” ] } ] }</p>
</blockquote>
<p>Replace<account-id>with your AWS account ID.</p>
<h4><strong>2. Create IAM Role</strong></h4>
<p>1. Save this trust policy as trust-policy.json:</p>
<blockquote>
<p>{ “Version”: “2012-10-17”, “Statement”: [ { “Effect”: “Allow”, “Principal”: { “Federated”: “arn:aws:iam::<account-id>:oidc-provider/oidc.eks.us-east-1.amazonaws.com/id/<oidc-id>” }, “Action”: “sts:AssumeRoleWithWebIdentity”, “Condition”: { “StringEquals”: { “oidc.eks.us-east-1.amazonaws.com/id/<oidc-id>:sub”: “system:serviceaccount:default:my-app-sa” } } } ] }</p>
</blockquote>
<p>2. Create the role and attach the policy:</p>
<blockquote>
<p>aws iam create-role –role-name eks-secret-access-role \ –assume-role-policy-document file://trust-policy.json aws iam put-role-policy –role-name eks-secret-access-role \ –policy-name secrets-access-policy \ –policy-document file://secrets-access-policy.json</p>
</blockquote>
<h3><strong>Step 5: Create Kubernetes Service Account</strong></h3>
<p>1. Save the following YAML as service-account.yaml:</p>
<blockquote>
<p>apiVersion: v1 kind: ServiceAccount metadata: name: my-app-sa namespace: default annotations: eks.amazonaws.com/role-arn: arn:aws:iam::<account-id>:role/eks-secret-access-role</p>
</blockquote>
<p>2. Apply the service account:</p>
<blockquote>
<p>kubectl apply -f service-account.yaml</p>
</blockquote>
<h3><strong>Step 6: Deploy the Application</strong></h3>
<h4><strong>1. Create Python Script</strong></h4>
<p>Save the following script as app.py:</p>
<blockquote>
<p>import boto3 import json def get_secret(secret_name, region_name=”us-east-1″): client = boto3.client(“secretsmanager”, region_name=region_name) try: response = client.get_secret_value(SecretId=secret_name) return response[“SecretString”] if “SecretString” in response else response[“SecretBinary”] except Exception as e: print(f”Error retrieving secret: {e}”) return None if __name__ == “__main__”: secret_name = “RambunctDatabaseSecret” secret = get_secret(secret_name) if secret: print(f”Fetched secret: {secret}”) else: print(“Failed to fetch secret”)</p>
</blockquote>
<h4><strong>2. Create ConfigMap</strong></h4>
<p>Store the script in a Kubernetes ConfigMap:</p>
<blockquote>
<p>kubectl create configmap app-script –from-file=app.py</p>
</blockquote>
<h4><strong>3. Create Deployment</strong></h4>
<p>Save the following YAML as<strong> deployment.yaml:</strong></p>
<blockquote>
<p>apiVersion: apps/v1 kind: Deployment metadata: name: my-app labels: app: my-app spec: replicas: 1 selector: matchLabels: app: my-app template: metadata: labels: app: my-app spec: serviceAccountName: my-app-sa containers: – name: python-app image: python:3.9-slim command: [“/bin/sh”, “-c”] args: – > pip install boto3 &#038;&#038; python /app/app.py; volumeMounts: – name: app-script mountPath: /app env: – name: AWS_REGION value: us-east-1 volumes: – name: app-script configMap: name: app-script</p>
</blockquote>
<h4>4. Apply the deployment:</h4>
<blockquote>
<p>kubectl apply -f deployment.yaml</p>
</blockquote>
<h3><strong>Step 7: Verify the Application</strong></h3>
<ol>
<li>Check the pod:<br /> kubectl get pods</li>
<li>View the logs:<br /> kubectl logs <pod-name></li>
</ol>
<p>The logs should display the secret retrieved from AWS Secrets Manager.</p>
<h3><strong>Conclusion</strong></h3>
<p>By following this guide, you’ve set up an EKS cluster, securely stored a secret in AWS Secrets Manager, and deployed an application that fetches the secret dynamically using IRSA. This workflow ensures that sensitive information is securely managed and accessed in a Kubernetes environment.</p>
<p>The post <a href="https://rc.global-exposure.co.uk/using-aws-secrets-manager-with-amazon-eks-for-secure-secrets-management/">Using AWS Secrets Manager with Amazon EKS for Secure Secrets Management</a> appeared first on <a href="https://rc.global-exposure.co.uk">Rambunct Consulting</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://rc.global-exposure.co.uk/using-aws-secrets-manager-with-amazon-eks-for-secure-secrets-management/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Building a Serverless API with Amazon API Gateway, AWS Lambda, and Amazon Cognito for User Authentication</title>
		<link>https://rc.global-exposure.co.uk/building-a-serverless-api-with-aws-api-gateway-lambda-and-cognito-for-user-authentication/</link>
					<comments>https://rc.global-exposure.co.uk/building-a-serverless-api-with-aws-api-gateway-lambda-and-cognito-for-user-authentication/#respond</comments>
		
		<dc:creator><![CDATA[admin]]></dc:creator>
		<pubDate>Mon, 17 Aug 2026 13:05:12 +0000</pubDate>
				<category><![CDATA[Security]]></category>
		<category><![CDATA[Serverless]]></category>
		<guid isPermaLink="false">https://rc.global-exposure.co.uk/?p=422</guid>

					<description><![CDATA[<p>In this blog, we will walk through the process of […]</p>
<p>The post <a href="https://rc.global-exposure.co.uk/building-a-serverless-api-with-aws-api-gateway-lambda-and-cognito-for-user-authentication/">Building a Serverless API with Amazon API Gateway, AWS Lambda, and Amazon Cognito for User Authentication</a> appeared first on <a href="https://rc.global-exposure.co.uk">Rambunct Consulting</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>In this blog, we will walk through the process of building a serverless API using Amazon API Gateway, AWS Lambda, and Amazon Cognito for user authentication. This stack provides a powerful and scalable way to create and manage APIs with minimal infrastructure management. By the end of this guide, you will have a secure, scalable, and cost-efficient API with user authentication integrated into it.</p>
<h3>Why Serverless?</h3>
<p>Before diving into the implementation details, it’s essential to understand why serverless architectures have gained so much popularity. Serverless computing abstracts away the need to manage servers, allowing developers to focus on code and business logic rather than worrying about infrastructure. AWS offers several services that support a serverless architecture, including API Gateway, Lambda, and Cognito:</p>
<ul>
<li><strong>Amazon API Gateway</strong> provides a fully managed service to create and expose RESTful APIs.</li>
<li><strong>AWS Lambda</strong> enables you to run code in response to events without provisioning or managing servers.</li>
<li><strong>Amazon Cognito</strong> offers authentication, authorization, and user management for your applications.</li>
</ul>
<p>Together, these services allow you to build scalable, secure, and cost-effective APIs.</p>
<h3>Steps to Build the Serverless API with User Authentication</h3>
<p>We’ll break this down into clear steps for building a serverless API with Amazon API Gateway, Lambda, and Cognito.</p>
<h4>Step 1: Set Up Amazon Cognito for User Authentication</h4>
<p>Amazon Cognito simplifies adding authentication and user management to your application. It allows you to easily create user pools, manage registration, authentication, and multi-factor authentication.</p>
<ol>
<li><strong>Create a Cognito User Pool</strong>: Navigate to the Amazon Cognito console. Define your application-specific user pool requirements. Configure the required options, such as sign-up attributes (e.g., email or phone number) and a return URL for redirecting users after successful login.</li>
<li><strong>Use the Login Page</strong>: Use the <strong>View login page</strong> option to access Cognito’s hosted UI for user authentication.</li>
<li><strong>App Client Configuration</strong>: Navigate to the login page and click on the “Edit” option. Go to OAuth 2.0 grant types and select <strong>“Implicit grant”</strong>. Using the login dashboard, sign up for an account. After successfully logging in, take note of the URL and copy the <strong>ID token</strong> for future use.</li>
</ol>
<h4>Step 2: Create a Lambda Function for API Logic</h4>
<p>Now we will write the core business logic of the API using AWS Lambda.</p>
<ol>
<li><strong>Create a New Lambda Function</strong>: Navigate to the Lambda service in the AWS Console and click <strong>Create function</strong>. Choose <strong>Author from scratch</strong> and select Node.js or Python (or any other language you prefer). Set up the Lambda function to execute based on your desired API logic (e.g., creating a resource, fetching data, etc.).</li>
</ol>
<blockquote>
<p><strong>Example Lambda Code</strong>: Below is a simple example of a Lambda function that responds with a greeting message: exports.handler = async (event) => {<br /> const name = event.queryStringParameters ? event.queryStringParameters.name : ‘World’;<br /> const response = {<br /> statusCode: 200,<br /> body: JSON.stringify({ message: `Hello, ${name}!` }),<br /> };<br /> return response;<br /> };</p>
</blockquote>
<p><strong>2. Configure Permissions</strong>:</p>
<ul>
<li>Make sure the Lambda function has the appropriate permissions to interact with other AWS services (if needed). You can define the permissions using IAM roles.</li>
</ul>
<h4>Step 3: Set Up Amazon API Gateway</h4>
<p>Now we will expose the Lambda function via Amazon API Gateway.</p>
<ol>
<li><strong>Create a New API Gateway</strong>: In the AWS Management Console, go to API Gateway and choose <strong>Create API</strong>. Select <strong>REST API</strong> and provide a name for your API.</li>
<li><strong>Configure the Resource</strong>: Navigate to the method settings, configure the method type as <strong>GET</strong>, and link it to the Lambda function created in the previous step.</li>
<li><strong>Enable Authorization with Cognito</strong>: Select the <strong>Authorizer</strong>. Create an authorizer using Amazon Cognito. Configure it based on the provided settings to match your requirements. Select the user pool you created earlier. This ensures that only authenticated users can access the API.</li>
<li><strong>Edit the Method Request</strong>: Navigate back to the method request settings and click on the “Edit” option. Select the authorizer that you previously created from the available options.</li>
<li><strong>Deploy the API</strong>: Once everything is set up, deploy the API by creating a new stage (e.g., dev). The API will now be live, and you can call it using the provided endpoint.</li>
</ol>
<h4>Step 4: Test the API</h4>
<ol>
<li><strong>Test Without Authentication</strong>: Try accessing your API without a token. You should get an <strong>unauthorized</strong> response.</li>
<li><strong>Test With Authentication</strong>: Authenticate using the ID token that you noted earlier. To test the API using Postman, follow these steps: Open Postman and create a new request. In the <strong>Headers</strong> section, add the following: <strong>Key</strong>: Authorization <strong>Value</strong>: (Paste the ID token here) Send the request, and you should receive the expected response if the authentication is successful. At this point, you should receive the expected response from the API, confirming successful authentication.</li>
</ol>
<h3>Conclusion</h3>
<p>You’ve now built a serverless API using Amazon API Gateway, AWS Lambda, and Amazon Cognito for user authentication. This stack allows you to build secure, scalable, and cost-effective APIs without worrying about server management. By leveraging AWS’s managed services, you can focus on your application’s core logic and let AWS handle the heavy lifting of authentication, authorization, and scaling.</p>
<p>This approach provides:</p>
<ul>
<li><strong>Scalability</strong>: Automatically scales to handle large amounts of traffic.</li>
<li><strong>Cost-efficiency</strong>: Pay only for what you use, with no infrastructure overhead.</li>
<li><strong>Security</strong>: Easy integration of secure authentication with Amazon Cognito.</li>
</ul>
<p>The post <a href="https://rc.global-exposure.co.uk/building-a-serverless-api-with-aws-api-gateway-lambda-and-cognito-for-user-authentication/">Building a Serverless API with Amazon API Gateway, AWS Lambda, and Amazon Cognito for User Authentication</a> appeared first on <a href="https://rc.global-exposure.co.uk">Rambunct Consulting</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://rc.global-exposure.co.uk/building-a-serverless-api-with-aws-api-gateway-lambda-and-cognito-for-user-authentication/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
