<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Miguel's Blog · Serverless · Security]]></title><description><![CDATA[Learn about cybersecurity, serverless, tech and finance.]]></description><link>https://miguelacallesmba.com</link><image><url>https://cdn.hashnode.com/res/hashnode/image/upload/v1634775828850/69UNEtjO_.png</url><title>Miguel&apos;s Blog · Serverless · Security</title><link>https://miguelacallesmba.com</link></image><generator>RSS for Node</generator><lastBuildDate>Wed, 15 Apr 2026 09:15:08 GMT</lastBuildDate><atom:link href="https://miguelacallesmba.com/rss.xml" rel="self" type="application/rss+xml"/><language><![CDATA[en]]></language><ttl>60</ttl><item><title><![CDATA[Stop Installing Node.js and Global Npm Packages, Use Docker Instead]]></title><description><![CDATA[There is a way to keep our computers isolated from malicious npm packages and cybersecurity vulnerabilities. It’s almost like Node and npm will be on an island.
We can use a Docker container to run Node.js and install npm packages.
What are Docker co...]]></description><link>https://miguelacallesmba.com/stop-installing-nodejs-and-global-npm-packages-use-docker-instead</link><guid isPermaLink="true">https://miguelacallesmba.com/stop-installing-nodejs-and-global-npm-packages-use-docker-instead</guid><category><![CDATA[Docker]]></category><category><![CDATA[containers]]></category><category><![CDATA[Node.js]]></category><category><![CDATA[npm]]></category><category><![CDATA[JavaScript]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Wed, 26 Jan 2022 08:00:00 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1645585355903/cpwtIPl-P.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>There is a way to keep our computers isolated from malicious npm packages and cybersecurity vulnerabilities. It’s almost like Node and npm will be on an island.</p>
<p>We can use a Docker container to run Node.js and install npm packages.</p>
<h2 id="heading-what-are-docker-containers-and-why-should-we-use-them">What are Docker containers and why should we use them?</h2>
<p>Docker is a software technology that creates a container that runs on our computer. A container is like running a mini computer within ours and restricts access to our files.</p>
<p>The problem with running Node.js on our computer is the growth of malicious npm packages. There are some malicious actors that purposely put malware in npm packages. They create packages with similar names (called typosquatting) hoping we will install the incorrect version so they can deliver the malware.</p>
<p>These types of npm attacks have been <a target="_blank" href="https://threatpost.com/5-top-threatpost-stories-2021/177278/">growing significantly</a> and will continue <a target="_blank" href="https://www.securityweek.com/cyber-insights-2022-supply-chain">being an issue in 2022</a> and future years.</p>
<p>What if we installed a malicious npm package and we can limit the extent of the damage? That is where containers can help.</p>
<p>Suppose we installed an <a target="_blank" href="https://blog.sonatype.com/fake-npm-roblox-api-package-installs-ransomware-spooky-surprise">npm package that deployed ransomware</a>. All our files would become a victim to the ransomware attack if we were running Node.js on our computer.</p>
<p>Suppose we installed it inside a container. A properly configured container will limit access to the files added to the container. In theory, only those specific files will be compromised and our personal files should be protected. We can stop the container, delete the container image, purge all files associated with the container, and run an antivirus scan just to be safe. Given we commit our code to a software repository, we probably only lost a little bit of our code.</p>
<p>Using a Docker container to run Node.js is like putting our code in quarantine so that an infection does not put a strain on the whole computer.</p>
<h2 id="heading-how-do-i-set-up-nodejs-and-npm-on-my-machine">How do I set up Node.js and npm on my machine?</h2>
<p>Start by installing <a target="_blank" href="https://www.docker.com/products/docker-desktop">Docker Desktop</a> on our development machine. We will want to create a Docker account also to take advantage Docker scan feature that we will discuss later.</p>
<p>After we install it, go to the settings.</p>
<p>Enable “Docker Compose V2” in the “General” section.</p>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/uploads/articles/ol2f14nexxt831hwge30.png" alt="Docker General settings." /></p>
<p><em>General settings.</em></p>
<p>Set the desired resource load in the “Resources Advanced” section.</p>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/uploads/articles/pqks19dzyh77i8ptpna8.png" alt="Docker Advanced Resources settings.
" /></p>
<p><em>Advanced Resources settings.</em></p>
<p>Ensure software updates are enabled.</p>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/uploads/articles/nscn578y7tknba4rt9qo.png" alt="Docker Software Updates settings." /></p>
<p><em>Software Updates settings.</em></p>
<p>Go to our code folder. Create a file called <code>docker-compose.yml</code> in the top-level directory (or in every folder that we want a customized container).</p>
<pre><code class="lang-yaml"><span class="hljs-attr">version:</span> <span class="hljs-string">"3"</span>
<span class="hljs-attr">services:</span>
  <span class="hljs-attr">dev:</span>
    <span class="hljs-attr">image:</span> <span class="hljs-string">"node:14.18.1-buster-slim"</span>
    <span class="hljs-attr">user:</span> <span class="hljs-string">"node"</span>
    <span class="hljs-attr">working_dir:</span> <span class="hljs-string">/home/node/dev</span>
    <span class="hljs-attr">volumes:</span>
      <span class="hljs-bullet">-</span> <span class="hljs-string">/var/run/docker.sock:/var/run/docker.sock</span>
      <span class="hljs-bullet">-</span> <span class="hljs-string">./:/home/node/dev</span>
</code></pre>
<p>The Docker Compose file creates and runs a Docker container without to build it.</p>
<p>The <code>image:</code> property defines the node container. The example uses an official Node.js container image. The version was selected based on the recommendation from the Docker scan.</p>
<p>The <code>working_dir:</code> property defines the home directory as <code>/home/node/dev</code>. (When we start the container it will show dev as the current folder.)</p>
<p>The <code>volumes:</code> property allows running Docker within container and puts all the files where the <code>docker-compose.yml</code> exists, and mounts them to the <code>/home/node/dev</code> directory within the container. (We can delete the first line if we do not need Docker running within the container.)</p>
<p>Using another image like one from Circle (e.g., <code>circleci/node:14-bullseye</code>) provides git and other common Linux utilities.</p>
<pre><code class="lang-yaml"><span class="hljs-attr">version:</span> <span class="hljs-string">"3"</span>
<span class="hljs-attr">services:</span>
  <span class="hljs-attr">node:</span>
    <span class="hljs-attr">image:</span> <span class="hljs-string">"circleci/node:14-bullseye"</span>
    <span class="hljs-attr">working_dir:</span> <span class="hljs-string">/home/node/dev</span>
    <span class="hljs-attr">volumes:</span>
      <span class="hljs-bullet">-</span> <span class="hljs-string">/var/run/docker.sock:/var/run/docker.sock</span>
      <span class="hljs-bullet">-</span> <span class="hljs-string">./:/home/node/dev</span>
</code></pre>
<p>In our computer’s terminal, run the following command to start the container.</p>
<pre><code class="lang-sh">docker compose run --rm dev bash
<span class="hljs-comment"># Or the following if Docker Compose v2 was not checked above</span>
docker-compose run --rm dev bash
</code></pre>
<p>We will now see a prompt like <code>node@502104098e72:~/code$</code> in the terminal. This means our terminal is now inside the Docker container running node.</p>
<p>Type the <code>ls</code> command to see our files. We should see our the files within the directory.</p>
<p>Open Docker Desktop and we will see our container running.</p>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/uploads/articles/o38a56sctqd0lg1yw6w1.png" alt="A Docker container is running." /></p>
<p><em>A container is running.</em></p>
<p>We can now run <code>npm i -g some_package_name</code> and <code>npm ci</code> within the container.</p>
<p>(If we have Node installed on our machine, we can try installing a different global npm package in our container. We open a new terminal window, try running the global npm package and we should get an error because it is only installed in our container.)</p>
<p>In the container’s terminal, type the <code>exit</code> command. Go to Docker Desktop and we should no longer see the container.</p>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/uploads/articles/qs7zlkdr31kcca12ylka.png" alt="No Docker container is running." /></p>
<p><em>No container is running.</em></p>
<p>The <code>--rm</code> flag in the <code>docker compose run</code> commands tells Docker to delete the container after it terminates. This way we can keep our machine cleaner.</p>
<h2 id="heading-keeping-docker-up-to-date-and-clean">Keeping Docker up to date and clean</h2>
<p>We should apply the Docker software updates when they become available.</p>
<p>After we apply the updates, we should scan our container for vulnerabilities with a <a target="_blank" href="https://docs.docker.com/engine/scan/">Docker scan</a>.</p>
<p>We need to accept the license to get started with Docker scan.</p>
<pre><code class="lang-sh">docker scan --accept-license --version
</code></pre>
<p>We can scan our Node.js container with the following command.</p>
<pre><code class="lang-sh">docker scan node
</code></pre>
<p>The scan output will recommend which container image to use. We will update the <code>image:</code> property within the <code>docker-compose.yml</code> file to have the recommend image.</p>
<p>Every so often we should clean up the images.</p>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/uploads/articles/nx0bsmsgrx4j533sm9ik.png" alt="Cleaning up Docker images." /></p>
<p><em>Cleaning up images.</em></p>
<p>And remove old volumes.</p>
<p><img src="https://dev-to-uploads.s3.amazonaws.com/uploads/articles/h1771jsgzynbbo35ignd.png" alt="Removing Docker volumes." /></p>
<p><em>Removing volumes.</em></p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>Using Docker containers is one way to protect our computers from malicious npm packages and Node.js vulnerabilities because code execution and runtimes are isolated to the container.</p>
<h3 id="heading-want-to-connect">Want to Connect?</h3>
<p><a target="_blank" href="https://miguelacallesmba.com/">Miguel</a> is a Principal Engineer and the author of the “<a target="_blank" href="https://serverlesssecuritybook.com/">Serverless Security</a>” book. He has worked on multiple serverless projects as a developer and security engineer, contributed to open-source serverless projects, and worked on large military systems in various engineering roles.</p>
<hr />

<p>Originally published on <a target="_blank" href="https://medium.com/better-programming/stop-installing-node-js-and-global-npm-packages-use-docker-instead-42597990db13">Medium</a></p>
<p>Photo by <a target="_blank" href="https://unsplash.com/@twinckels">Tom Winckels</a> on <a target="_blank" href="https://unsplash.com/">Unsplash</a></p>
]]></content:encoded></item><item><title><![CDATA[Taking calculated risks]]></title><description><![CDATA[Questioning assumptions and being willing to deviate from your boss’ instructions can be scary.

It was about ten years ago, and the director of engineering took a chance on me. She assigned me to work on a mega-multi-million dollar program. This pro...]]></description><link>https://miguelacallesmba.com/taking-calculated-risks</link><guid isPermaLink="true">https://miguelacallesmba.com/taking-calculated-risks</guid><category><![CDATA[Career]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Fri, 10 Dec 2021 17:55:37 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1640886558419/3BcQMKBRO.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Questioning assumptions and being willing to deviate from your boss’ instructions can be scary.</p>
<hr />
<p>It was about ten years ago, and the director of engineering took a chance on me. She assigned me to work on a mega-multi-million dollar program. This program also had several million dollars in incentives if the project achieved milestones ahead of schedule. This project was a big deal, and I was assigned to be the first team member of the networking engineering team.</p>
<p>The team only had the manager and the technical lead. The team needed to build a large multi-site and resilient network for this important customer. I had never worked with these two leads before. Yet, the technical lead told me I would be responsible for designing and building the voice over IP (VOIP) phone system.</p>
<p>I had never built a VOIP phone system before. I was still relatively new to networking engineering too. Now another person was taking a chance on me.</p>
<p>Usually, I would have been too afraid and chickened out. This was a big responsibility with a lot at stake.</p>
<p>I did not realize at first that this customer relied more on the phone systems than on the computer systems to do their work. The phone system had to be more resilient and better designed than the computer systems. (Of course, the network had to be just as resilient to support the VOIP phone system too.)</p>
<p>To top it off, I would be the only person designing and building the phone system. In contrast, the manager would bring in several people to work on the network.</p>
<p>How could such an important system be assigned to someone who had never even built one?</p>
<p>Rather than chicken out, I went against my nature and took on the challenge.</p>
<hr />
<p>I spent two months reading the customer requirements and the VOIP system technical manuals. I made sure I read every page of those manuals and the customer requirement documents. I ensured every requirement could trace back to the VOIP functionality presented in the manuals.</p>
<p>When it came time to meet with the technical lead to discuss design, I answered most of the questions. I took action to research those I could not answer.</p>
<p>The technical lead had built phone systems with bare-metal systems. Learning about his experience over the past several decades was eye-opening. A lot went into powering and supporting a “simple” phone call.</p>
<p>I typically would have followed the same patterns and the guidance from my technical lead. Why not? He had several decades of experience when I did not. Yet, it did not play out that way.</p>
<hr />
<p>I had several meetings with the sales engineers from the company from which we would be buying the VOIP technology. Those people were very knowledgeable.</p>
<p>I had remembered reading about virtualization technology, and I inquired about it. They assured me this new technology would achieve the same results as the bare metal solutions. I took a note and researched it some more.</p>
<p>The more I read about it, the more I was impressed. This seemed like the future. I asked some fellow network engineers about this. They had not used this yet in any previous system. Would I dare take the plunge and propose a new technique for this high-value customer?</p>
<hr />
<p>I eventually proposed the virtualization design to the technical lead. He was pretty upset and wary. This was new. This was different. This seemed very risky.</p>
<p>I remember he told me something like, “We will try it and present it to the project’s technical director. If he doesn’t like it, it’ll be on you.”</p>
<p>This seemed acceptable. I agreed.</p>
<hr />
<p>The technical lead presented the design to the technical director. He had some questions and seemed pensive. He asked some questions on design items I had not considered. After all, he did not become a technical director without thoroughly assessing systems for resiliency.</p>
<p>I took note of the technical director’s concerns.</p>
<p>What happened next shook me and stuck with me.</p>
<p>My technical lead turned to me and said, “I knew I never should have listened to your virtualization idea.”</p>
<p>I felt I messed up royally.</p>
<hr />
<p>As I researched the answers to the technical director’s questions, I realized that the questions were good. He was not questioning the design but making sure the design was resilient. There were no negative comments from the director — only from my lead. Maybe the director could accept the new virtualization design.</p>
<p>I found the answers and submitted them to my lead, who presented the findings to the technical director. The technical director liked the explanations and approved the design.</p>
<hr />
<p>When it came to procuring hardware six months later, we did not have to procure separate hardware for the VOIP system. We could simply use the servers that we already needed to buy for the data center we were building. Furthermore, we could simplify the network design too.</p>
<p>By adopting virtualization for the VOIP systems, we were able to save about $1 million in hardware costs.</p>
<p>(As an added bonus: the network engineers and the technical lead had a much easier time installing the VOIP system at all the customer sites. It would have been nice to have been there too, but I could not travel for personal reasons.)</p>
<h3 id="heading-conclusion">Conclusion</h3>
<p>Preparation was essential to achieve this good outcome. I spent a lot of time working on my assignment. With the knowledge I had acquired, I could spot an opportunity that I would have missed otherwise. I respected my technical lead’s and the technical director’s concerns, and made sure I answered any questions as best as I could. Having the preparation in place, I was able to take a calculated risk that paid off.</p>
<p>Don’t be afraid to take a risk, especially when you’ve done your homework.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p>Originally published on <a target="_blank" href="https://medium.com/nerd-for-tech/how-i-saved-my-company-1-million-be99fd125978">Medium</a></p>
<p>Photo by <a href="https://unsplash.com/@euniveeerse">Eunice Lituañas</a> on <a href="https://unsplash.com/">Unsplash</a></p>
]]></content:encoded></item><item><title><![CDATA[Overview of the OWASP Serverless Top 10 [videos]]]></title><description><![CDATA[This YouTube video series provides quick overviews of the top 10 cybersecurity risks for serverless applications. Each video covers the risk and some recommendations on how to address it.
Why is the OWASP Serverless Top 10 important?
In this video, I...]]></description><link>https://miguelacallesmba.com/overview-of-the-owasp-serverless-top-10-videos</link><guid isPermaLink="true">https://miguelacallesmba.com/overview-of-the-owasp-serverless-top-10-videos</guid><category><![CDATA[serverless]]></category><category><![CDATA[Security]]></category><category><![CDATA[#cybersecurity]]></category><category><![CDATA[AWS]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Mon, 08 Nov 2021 21:55:22 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1636408504092/BcNttK9q2.png" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>This YouTube video series provides quick overviews of the top 10 cybersecurity risks for serverless applications. Each video covers the risk and some recommendations on how to address it.</p>
<h1 id="heading-why-is-the-owasp-serverless-top-10-important">Why is the OWASP Serverless Top 10 important?</h1>
<p>In this video, I discussed the reasons why the OWASP Serverless Top 10 cybersecurity risks for a serverless application are important to consider.</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=wWDzqrvt73A">https://www.youtube.com/watch?v=wWDzqrvt73A</a></div>
<h1 id="heading-injection-attacks">Injection attacks</h1>
<p>In this video, I discussed what is the injection attack.</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=QhmAs30-b_k">https://www.youtube.com/watch?v=QhmAs30-b_k</a></div>
<h1 id="heading-broken-authorization">Broken authorization</h1>
<p>In this video, I discussed what is broken authentication and authorization.</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=fDO4n3HrvQw">https://www.youtube.com/watch?v=fDO4n3HrvQw</a></div>
<h1 id="heading-sensitive-data-exposure">Sensitive data exposure</h1>
<p>In this video, I discussed the sensitive data exposure risk.</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=Q8j8Cu0jhqc">https://www.youtube.com/watch?v=Q8j8Cu0jhqc</a></div>
<h1 id="heading-xml-external-entities">XML external entities</h1>
<p>In this video, I discussed the XML external entities risk.</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=wtgTtYXenyM">https://www.youtube.com/watch?v=wtgTtYXenyM</a></div>
<h1 id="heading-broken-access-control">Broken access control</h1>
<p>In this video, I discussed the broken access control risk.</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=nqBQdAiTOb8">https://www.youtube.com/watch?v=nqBQdAiTOb8</a></div>
<h1 id="heading-security-misconfiguration">Security misconfiguration</h1>
<p>In this video, I discussed the security misconfiguration risk.</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=yDyYqDGph8c">https://www.youtube.com/watch?v=yDyYqDGph8c</a></div>
<h1 id="heading-cross-site-script-attacks">Cross-site script attacks</h1>
<p>In this video, I discussed the cross-site scripting (XSS).</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=jyLOBsHg-7c">https://www.youtube.com/watch?v=jyLOBsHg-7c</a></div>
<h1 id="heading-insecure-deserialization">Insecure deserialization</h1>
<p>In this video, I discussed the insecure deserialization risk.</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=RlV79AmI6Yw">https://www.youtube.com/watch?v=RlV79AmI6Yw</a></div>
<h1 id="heading-vulnerable-components">Vulnerable components</h1>
<p>In this video, I discussed the risk of using components with known vulnerabilities.</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=Ij6xU48K11k">https://www.youtube.com/watch?v=Ij6xU48K11k</a></div>
<h1 id="heading-logging-and-monitoring">Logging and monitoring</h1>
<p>In this video, I discussed the insufficient logging and monitoring risk.</p>
<div class="embed-wrapper"><div class="embed-loading"><div class="loadingRow"></div><div class="loadingRow"></div></div><a class="embed-card" href="https://www.youtube.com/watch?v=2Alu17kfNQA">https://www.youtube.com/watch?v=2Alu17kfNQA</a></div>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div>]]></content:encoded></item><item><title><![CDATA[How sharing an accomplishment lead to the realization of a life goal]]></title><description><![CDATA[A little over one year ago, I published my first book thanks to Apress and author Nihad Hassan.
I am in a cybersecurity writing group with Nihad, where he shared he had published his 4th book; this was back in 2019. I was impressed by his accomplishm...]]></description><link>https://miguelacallesmba.com/how-sharing-an-accomplishment-lead-to-the-realization-of-a-life-goal</link><guid isPermaLink="true">https://miguelacallesmba.com/how-sharing-an-accomplishment-lead-to-the-realization-of-a-life-goal</guid><category><![CDATA[Inspiration]]></category><category><![CDATA[ideas]]></category><category><![CDATA[life]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Mon, 18 Oct 2021 19:56:14 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1634586717201/DIx_-mKQJ.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>A little over one year ago, I published my first book thanks to Apress and author Nihad Hassan.</p>
<p>I am in a cybersecurity writing group with Nihad, where he shared he had published his 4th book; this was back in 2019. I was impressed by his accomplishment, and it made me wonder, "Maybe I could write a book too."</p>
<p>I read about the Apress author program and tucked it away in my memory.</p>
<p>A few months later, I started wondering why information on serverless security was so disparate. It was almost the summer of 2019, and I did not see one book published on serverless security.</p>
<p>I realized there was a need to be filled. Maybe this was my opportunity to write my first traditionally published book.</p>
<p>The rest is history, and Serverless Security was published on October 6, 2020.</p>
<p>I wrote this post for two reasons.</p>
<ol>
<li><p>Thank Nihad for his inspiration and Apress for making it become a reality.</p>
</li>
<li><p>To share that an idea and life goal can be achieved, and by sharing our accomplishments, we can inspire others to achieve their goals and realize their ideas and dreams.</p>
</li>
</ol>
<p>Go ideate, execute and make your ideas a reality.</p>
<p>Happy Monday!</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p>Photo by  <a target="_blank" href="https://unsplash.com/@adigold1">Adi Goldstein</a> on <a target="_blank" href="https://unsplash.com/s/photos/birthday">Unsplash</a>  </p>
]]></content:encoded></item><item><title><![CDATA[If you build it, you should break it.]]></title><description><![CDATA[You may have heard, “If you build it, they will come.”
Have you heard, “If you build it, I will break it?”
This is a skill I developed over my career to build better systems. It is a skill that took me a while to learn I had.
Shortly before I graduat...]]></description><link>https://miguelacallesmba.com/if-you-build-it-you-should-break-it</link><guid isPermaLink="true">https://miguelacallesmba.com/if-you-build-it-you-should-break-it</guid><category><![CDATA[Career]]></category><category><![CDATA[Developer]]></category><category><![CDATA[Testing]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Sat, 16 Oct 2021 22:45:46 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1634424254062/GOyR7fBnz.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>You may have heard, “If you build it, they will come.”</p>
<p>Have you heard, “If you build it, I will break it?”</p>
<p>This is a skill I developed over my career to build better systems. It is a skill that took me a while to learn I had.</p>
<p>Shortly before I graduated from college, I decided to leave the material science industry because I had a tendency to break stuff. When working with toxic substances, this can be hazardous. As a result, I changed to the systems engineering field.</p>
<p>It turned out I had a knack for breaking stuff there too. For a long while, I avoided working on things I could break. Yet, I found I wasn’t growing as much as my peers. So I decided I needed to do some hands-on work.</p>
<p>As it turns out, I was breaking stuff, and people were getting mad. They had to fix deficiencies and errors I discovered. A time came people started expecting me to fix what I broke. That was a pivotal moment in my career.</p>
<p>I had to learn how to fix things, and I wasn’t trained as an engineer. My undergrad was in material science. I started learning how to fix things and became more knowledgeable about the technology. I eventually learned how to find defects, flaws, and deficiencies in designs.</p>
<p>I turned what I thought was a flaw into a skill. I could help build more reliable systems by “breaking them.” Penetration testers do this type of work. They look for vulnerabilities and ways to break “in.” I had a knack for finding ways to break “down” systems. If I can learn why a system could falter, I can help prevent it.</p>
<p>My recommendation for your systems: Plan to break your system before it breaks on you.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on  <a target="_blank" href="https://miguelacallesmba.medium.com/if-you-build-it-you-should-break-it-25e06f2d53b6">Medium</a> </em></p>
<p>Photo by  <a target="_blank" href="https://unsplash.com/@marcrafanell">Marc Rafanell López</a> on  <a target="_blank" href="https://unsplash.com/@marcrafanell">Unsplash</a></p>
]]></content:encoded></item><item><title><![CDATA[Can Infosec Professionals Be Vulnerable To Phishing?]]></title><description><![CDATA[Multitasking can be a dangerous thing. Our minds are trying to get a lot done, and we might be less focused than we should. Malicious actors are hoping we are careless so that we make mistakes. Given that, I believe a security engineer is just as lik...]]></description><link>https://miguelacallesmba.com/can-infosec-professionals-be-vulnerable-to-phishing</link><guid isPermaLink="true">https://miguelacallesmba.com/can-infosec-professionals-be-vulnerable-to-phishing</guid><category><![CDATA[#cybersecurity]]></category><category><![CDATA[Security]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Sun, 25 Jul 2021 22:46:20 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1627253173576/uhdJAINK0.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Multitasking can be a dangerous thing. Our minds are trying to get a lot done, and we might be less focused than we should. Malicious actors are hoping we are careless so that we make mistakes. Given that, I believe a security engineer is just as likely to get phished. I wanted to know what others thought by creating polls.</p>
<h2 id="heading-polls-on-linkedin-and-twitter">Polls on LinkedIn and Twitter</h2>
<p>I wanted to know what my social networks thought about this question. I already had my own opinion and experience, but did others share my view?</p>
<p>I structured the LinkedIn and Twitter polls to not only get a "yes" or "no" answer. There were designed to assess whether being phished affected responses. The first two options for each "yes" and "no" answer were aimed to figure out which participants might have been phished themselves. The second options for each "yes" and "no" answer were to see who has not been phished.</p>
<p>I received very few responses, but the results were still illuminating.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1627252923209/o2F3jXLPL.png" alt="linkedin-poll-results-could-security-engineer-be-phished.png" />
<em>LinkedIn poll results</em></p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1627252932044/E6uqVkDgi.png" alt="twitter-poll-results-could-security-engineer-be-phished.png" />
<em>Twitter poll results</em></p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1627252937720/SbWqvvBNm.png" alt="combined-poll-results-could-security-engineer-be-phished.png" />
<em>Combined poll results</em></p>
<h2 id="heading-poll-results">Poll results</h2>
<p>Surprisingly, many respondents believe security engineers cannot be vulnerable to phishing. This belief highlights security engineers have become well respected. This respect may be due to the increased awareness of the need for cybersecurity. I see a concern here: security engineers could become overconfident and make more mistakes, thus becoming future targets. Although the majority thought security engineers could not get phished, no one ruled out the possibility.</p>
<p>Of the remainder who answered "yes," the majority were not phished. I was supposing that many of the "yes" answers would come from individuals who themselves were phished. Surprisingly that was not the case. It seems those who answered "yes" are being realistic that anyone could get phished even though they were not.</p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>The number of responses were small and cannot be representative of everyone. It was surprising to learn that the majority of the respondents thought a security engineer could not be phished, but they did not rule out the possibility.</p>
<p>Personally, I think anyone is vulnerable to phishing, and that includes security engineers, security directors and chief information security officers.</p>
<p>Slow down and think. Whoever is asking for an urgent response can wait. If it was so critical, that person would have called many times and gotten the phone number from an acquaintance if needed.</p>
<p>Stay secure and alert,
Miguel</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on <a target="_blank" href="https://www.secjuice.com/poll-survey-results-phishing-security-engineers/">Secjuice</a></em></p>
<p><em>Photo by <a target="_blank" href="https://unsplash.com/@rachelhisko">Rachel Hisko</a> on <a target="_blank" href="https://unsplash.com/s/photos/fish">Unsplash</a></em> </p>
]]></content:encoded></item><item><title><![CDATA[Hacked via your calendar?]]></title><description><![CDATA[Someone asked me, "I think I have a virus on my iPhone. Could you take a look?"
I was surprised. I did not think viruses were technically possible on iOS devices.
I agreed to help.
I asked, "What did you notice that makes you think you have a virus?"...]]></description><link>https://miguelacallesmba.com/hacked-via-your-calendar</link><guid isPermaLink="true">https://miguelacallesmba.com/hacked-via-your-calendar</guid><category><![CDATA[#cybersecurity]]></category><category><![CDATA[Security]]></category><category><![CDATA[iOS]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Sat, 10 Jul 2021 21:46:19 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1625953402866/-kHIP8qib.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Someone asked me, "I think I have a virus on my iPhone. Could you take a look?"</p>
<p>I was surprised. I did not think viruses were technically possible on iOS devices.</p>
<p>I agreed to help.</p>
<p>I asked, "What did you notice that makes you think you have a virus?"</p>
<p>This person replied, "I started seeing pop-ups telling me I was hacked."</p>
<p>I pondered the response. "What app were you using?"</p>
<p>"I was using the Google app."</p>
<p>"Do you remember what you were doing there?"</p>
<p>"I searched for a former president's name and clicked the search result. It didn't take me to a website. Instead, it took me back to the Google search page."</p>
<p>I pondered the response. How could searching a president's name get oneself hacked?</p>
<p>"Look!" this person said. "The pop-up is there."</p>
<p>I looked at the phone and saw it was a calendar reminder notification. Interesting!</p>
<p>I opened the calendar app and saw calendar entries with scary titles and links to potential phishing sites.</p>
<p>Hacking through someone's calendar?! These malicious actors are incredibly clever.</p>
<p>I removed the subscribed calendar account and asked this person to clear the cache from all the web browsing apps.</p>
<p>I used my own device to find out how this was possible. I found an article that explains it. (See the link below). Turns out this is a relatively new attack vector.</p>
<p> <a target="_blank" href="https://macsecurity.net/view/333-iphone-calendar-events-spam">https://macsecurity.net/view/333-iphone-calendar-events-spam</a> </p>
<p>I asked, "Do you remember clicking some alert when you were browsing the web?"</p>
<p>"Well, yes. I got an alert. It had a button that said, 'Okay, got it." So, I clicked it. I don't remember what it said."</p>
<p>I suppose this person clicked a malicious pop-up alert that subscribed the calendar to a malicious shared calendar.</p>
<p>Fortunately, this person did not click on any of the calendar notifications. The bad news: this event reminded me that cyber defenders could continue to be behind the cyber attackers. I would not have considered an attack via a calendar app.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally posted on <a target="_blank" href="https://www.patreon.com/posts/53268712">Patreon</a></em></p>
<p><em>Photo by <a target="_blank" href="https://unsplash.com/@esteejanssens">Estée Janssens</a> on  <a target="_blank" href="https://unsplash.com/s/photos/calendar">Unsplash</a></em></p>
]]></content:encoded></item><item><title><![CDATA[Create a website on AWS with Serverless Framework plugins]]></title><description><![CDATA[The Serverless Framework allows us to create serverless websites. These websites use the S3, CloudFront, Route 53, and Certificate Manager AWS services. We can set up all four on AWS using Serverless plugins.
What is a serverless website?
A serverles...]]></description><link>https://miguelacallesmba.com/create-a-website-on-aws-with-serverless-framework-plugins</link><guid isPermaLink="true">https://miguelacallesmba.com/create-a-website-on-aws-with-serverless-framework-plugins</guid><category><![CDATA[serverless]]></category><category><![CDATA[website]]></category><category><![CDATA[Web Development]]></category><category><![CDATA[AWS]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Sun, 27 Jun 2021 18:01:13 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1624816821862/0yWINHIT_.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>The Serverless Framework allows us to create serverless websites. These websites use the S3, CloudFront, Route 53, and Certificate Manager AWS services. We can set up all four on AWS using Serverless plugins.</p>
<h2 id="heading-what-is-a-serverless-website">What is a serverless website?</h2>
<p>A serverless website is a website that runs without a server. It may seem impossible because every website needs a server. Object storage services (e.g., S3) allow serving HTML files and their supporting files. The browser just needs the HTML files, and it will fetch all the related files based on the HTML code. Think of simple HTML websites with dynamic code (e.g., PHP or Python).</p>
<h2 id="heading-what-do-i-need-to-create-a-serverless-website">What do I need to create a serverless website?</h2>
<p>You will need static web page files (i.e., HTML, JavaScript, CSS, and image files). If the website correctly displays in a browser by double-clicking the file on your computer, it will work as a serverless website.</p>
<p>You will need an AWS account. You will need a credit card to sign up for AWS. AWS accounts are free, but you pay for any services that you use. Fortunately, serverless websites are very cheap. I host three serverless websites for $0.05 per month.</p>
<p>You will probably want a custom domain to have a readable website address. You can buy one on AWS or use a domain name provider. This post assumes you already have a custom domain.</p>
<p>You will need the Serverless Framework to follow along with the rest of this post. Use the Serverless docs to <a target="_blank" href="https://www.serverless.com/framework/docs/providers/aws/guide/quick-start/">install and set up the Serverless Framework</a>.</p>
<h2 id="heading-setting-up-the-domain-with-route-53">Setting up the domain with Route 53</h2>
<p>Route 53 is the AWS service that deals with domain names and DNS records. We will need to set up a Route 53 hosted zone to create the domain name records required to route the custom domain name to the serverless website.</p>
<p>We will use a Serverless Framework plugin to create the hosted zone: the <a target="_blank" href="https://github.com/miguel-a-calles-mba/serverless-hosted-zone">serverless-hosted-zone</a> plugin.</p>
<p>To install it:</p>
<pre><code class="lang-sh"><span class="hljs-built_in">cd</span> to-my-serverless-project
npm install --save-dev serverless-hosted-zone
</code></pre>
<p>To add it to the <code>serverless.yml</code> configuration file:</p>
<pre><code class="lang-yaml"><span class="hljs-attr">plugins:</span>
  <span class="hljs-comment"># add to the previous entries</span>
  <span class="hljs-bullet">-</span> <span class="hljs-string">serverless-hosted-zone</span>

<span class="hljs-attr">custom:</span>
  <span class="hljs-comment"># add to the previous entries</span>
  <span class="hljs-comment"># see the documentation for all the options</span>
  <span class="hljs-attr">hostedZone:</span>
    <span class="hljs-attr">name:</span> <span class="hljs-string">customdomain.com.</span> <span class="hljs-comment"># Note the trailing dot</span>
</code></pre>
<p>To create the hosted zone:</p>
<pre><code class="lang-sh">sls create-zone
</code></pre>
<p>Now we have a hosted zone in our AWS account for the customdomain.com domain name.</p>
<h2 id="heading-setting-up-a-certificate">Setting up a certificate</h2>
<p>The AWS Certificate Manager service allows us to create a free certificate. That way, we can use HTTPS for our serverless website (and make Google and our website visitors feel happy and safe).</p>
<p>We will use a Serverless Framework plugin to create the hosted zone: the <a target="_blank" href="https://github.com/schwamster/serverless-certificate-creator">serverless-certificate-creator
</a> plugin.</p>
<p>To install it:</p>
<pre><code class="lang-sh">npm i --save-dev serverless-certificate-creator
</code></pre>
<p>To add it to the <code>serverless.yml</code> configuration file:</p>
<pre><code class="lang-yaml"><span class="hljs-attr">plugins:</span>
  <span class="hljs-comment"># add to the previous entries</span>
  <span class="hljs-bullet">-</span> <span class="hljs-string">serverless-certificate-creator</span>

<span class="hljs-attr">custom:</span>
  <span class="hljs-comment"># add to the previous entries</span>
  <span class="hljs-comment"># see the documentation for all the options</span>
  <span class="hljs-attr">customCertificate:</span>
    <span class="hljs-attr">certificateName:</span> <span class="hljs-string">customdomain.com</span>
    <span class="hljs-attr">idempotencyToken:</span> <span class="hljs-string">customdomaincom</span>
    <span class="hljs-attr">hostedZoneNames:</span> <span class="hljs-string">customdomain.com.</span> <span class="hljs-comment"># Note the trailing dot</span>
</code></pre>
<p>To create the certificate:</p>
<pre><code class="lang-sh">sls create-cert
</code></pre>
<p>The plugin creates the certificate and registers the DNS records in the hosted zone.</p>
<h2 id="heading-creating-the-serverless-website-hosting">Creating the serverless website hosting</h2>
<p>We will assume you already have the static HTML files you want to use for your serverless website. We will create an S3 bucket and a CloudFront distribution for our website. S3 is the object storage where we upload and serve our website files. CloudFront is a Content Delivery Network (CDN) to efficiently serve the website files. We will associate the certificate to the CloudFront distribution.</p>
<p>We will use a Serverless Framework plugin to create the S3 bucket and CloudFront distribution: the <a target="_blank" href="https://github.com/MadSkills-io/fullstack-serverless">fullstack-serverless
</a> plugin.</p>
<p>To install it:</p>
<pre><code class="lang-sh">npm install -g serverless
</code></pre>
<p>To add it to the <code>serverless.yml</code> configuration file:</p>
<pre><code class="lang-yaml"><span class="hljs-attr">plugins:</span>
  <span class="hljs-comment"># add to the previous entries</span>
  <span class="hljs-bullet">-</span> <span class="hljs-string">fullstack-serverless</span>

<span class="hljs-attr">custom:</span>
  <span class="hljs-comment"># add to the previous entries</span>
  <span class="hljs-comment"># see the documentation for all the options</span>
  <span class="hljs-attr">fullstack:</span>
    <span class="hljs-attr">domain:</span> <span class="hljs-string">customdomain.com</span>
    <span class="hljs-attr">certificate: arn:aws:acm:us-east-1:</span> <span class="hljs-comment"># use the actual ARN</span>
    <span class="hljs-attr">bucketName:</span> <span class="hljs-string">customdomain.com</span> <span class="hljs-comment"># the desired bucket name</span>
    <span class="hljs-attr">distributionFolder:</span> <span class="hljs-string">my-website-files-dir</span> <span class="hljs-comment"># assumes it is in the  same directory</span>
    <span class="hljs-attr">indexDocument:</span> <span class="hljs-string">index.html</span>
    <span class="hljs-attr">errorDocument:</span> <span class="hljs-string">error.html</span>
    <span class="hljs-attr">singlePageApp:</span> <span class="hljs-literal">true</span>
    <span class="hljs-attr">compressWebContent:</span> <span class="hljs-literal">true</span>
</code></pre>
<p>To deploy your static HTML website:</p>
<pre><code class="lang-sh"><span class="hljs-comment"># no-generate-client option because only using static files</span>
<span class="hljs-comment"># omit if you are using a reactive framework (e.g., React, Vue, Nuxt, Next)</span>
serverless client deploy --no-generate-client
</code></pre>
<h2 id="heading-updating-the-domain-name-pointer">Updating the domain name pointer</h2>
<p>If you bought your domain name within AWS Route 53, there is nothing left to do. AWS created automatically created the <code>customdomain.com.</code> hosted zone for you and the plugin checked for it.</p>
<p>If you bought it somewhere else, you should update the DNS records with that provider and point it to the CloudFront distribution.</p>
<p>You may have noticed the plugin output a DNS name (e.g., <code>abc1d2efghij4.cloudfront.net.</code>), or you can go to the AWS console to get the CloudFront distribution DNS name. Go to your DNS provider and create an ALIAS record pointing to <code>abc1d2efghij4.cloudfront.net.</code> so anyone that visits <code>https://customdomain.com</code> will see your new serverless website.</p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>With three Serverless Framework plugins, we created a serverless website to serve static HTML files. We can use this same approach to serve a Single Page Application designed with a reactive framework (e.g., React or Vue). We should point our domain name to our new serverless website if we purchased the domain outside of AWS.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on <a target="_blank" href="https://dev.to/miguelacallesmba/create-a-serverless-web-site-on-aws-with-serverless-plugins-35jc">dev.to</a></em></p>
<p><em>Photo by <a target="_blank" href="https://unsplash.com/@kobuagency">KOBU Agency</a> on <a target="_blank" href="https://unsplash.com/s/photos/web-site">Unsplash</a></em></p>
]]></content:encoded></item><item><title><![CDATA[Build a new Internet with a Helium miner and make passive income for you or others]]></title><description><![CDATA[The Internet was born in the last century, and most of the world was unable to contribute to building it. There is a new revolution where anyone willing to make a stimulus-sized investment can participate.
Introducing Helium and the People’s Network
...]]></description><link>https://miguelacallesmba.com/build-a-new-internet-with-a-helium-miner-and-make-passive-income-for-you-or-others</link><guid isPermaLink="true">https://miguelacallesmba.com/build-a-new-internet-with-a-helium-miner-and-make-passive-income-for-you-or-others</guid><category><![CDATA[internet]]></category><category><![CDATA[Internet of Things]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Sun, 27 Jun 2021 15:31:05 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1624806016730/KpxxLcF5e.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>The Internet was born in the last century, and most of the world was unable to contribute to building it. There is a new revolution where anyone willing to make a stimulus-sized investment can participate.</p>
<h2 id="heading-introducing-helium-and-the-peoples-network">Introducing Helium and the People’s Network</h2>
<p>Helium created a new wireless network that uses Long Range WAN (LoRaWAN) technology—they call it LongFi. This technology builds the People’s Network, where anyone can contribute to the infrastructure and use it for data transfer. Anyone can buy a Helium hotspot from $500-$600 with taxes and shipping. (This is roughly one of the United Status stimulus checks sent out for one person.) Once you set up your hotspot, connect it to your home network and join the Helium network, you can start earning the HNT cryptocurrency.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1624807746876/3zuhrbfbQ.png" alt="image.png" /></p>
<p><em>Bobcat miner for Helium</em></p>
<h2 id="heading-earnings-potential">Earnings potential</h2>
<p>The Helium miners build the network and are rewarded with HNT for various activities. Imagine investing $600 in a miner, and it earns $1,600 in the first month. You have recovered your start-up costs and gained $1,000 in gains! That’s amazing. See the example hotspot below that shows proof it is possible.</p>
<p>Furthermore, the price of HNT may increase in value when the HNT halving happens in August 2021. That $1,000 in gains could grow.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1624807695457/UsF-UJEMZ.png" alt="image.png" /></p>
<p><em>This hotspot earned almost 160 HNT. (An HNT is about $10 at the time of this writing.)</em></p>
<h2 id="heading-helping-yourself-andor-others">Helping yourself and/or others</h2>
<p>Participating in the People’s Network with a miner can provide you with a passive income source. But what if you could use it to benefit others? Imaging buying a miner for a cash-strapped family, that college student who is unable to pay tuition and board or your favorite non-profit, and sharing your HNT income. Not only would you be helping build a new network, but you are now helping those in need.</p>
<h2 id="heading-maximizing-the-earnings-potential">Maximizing the earnings potential</h2>
<p>There is no guarantee that each miner will earn the same amount of HNT. Many factors contribute to earnings (e.g., location, antenna gain, elevation, etc.). You will want to  <a target="_blank" href="https://www.nowitness.org/tuning-your-hotspot/">tune your hotspot</a> to maximize the earnings potential.</p>
<h2 id="heading-risks">Risks</h2>
<p>There are potential risks. Here are some:</p>
<ul>
<li>Introducing a new device to your home network could be a cybersecurity threat.</li>
<li>You may have added costs (e.g., upgrading your home Internet speed to support this new device and increased electricity usage).</li>
<li>Falling victim to scams (e.g., attempting to buy a miner from a fake miner web sites).</li>
<li>Losing access to your Helium wallet by losing the secret key.
-Having your Helium wallet stolen.</li>
</ul>
<p>There are many risks when it comes to new technologies and cryptocurrency in general.</p>
<h2 id="heading-rewards">Rewards</h2>
<p>These are some rewards I can think of:</p>
<ul>
<li>Earn passive income for you, someone else in need, or a non-profit.</li>
<li>Participate in a new technology revolution.</li>
<li>Use the network to send Internet of Things (IoT) data at a low rate.</li>
<li>Build a network that enables the creation of new ideas and inventions.</li>
<li>Join the world of cryptocurrency.</li>
</ul>
<p>There are many other rewards that I have not listed.</p>
<h2 id="heading-why-did-i-decide-to-participate">Why did I decide to participate?</h2>
<p>I accidentally stumbled onto Helium while I was researching and learning about cryptocurrencies. I loved the concept from the start. I came from a networking background and have dabbled in IoT. The thought of building a new type of network that was decentralized, long-range, durable, and scalable was impressive on its own. But knowing that anyone who helps build it gets incentivized made this project lovable.</p>
<p>It took me a couple weeks before I decided the spend over $500 to buy my first hotspot. “Was it worth the risk?” was a question I needed to answer. After researching the earnings potential from other hotspots, better understanding the technology, and determining the return on investment (ROI), I was sold. It would take me three months to get my miner, and it could take up to three months to get a return on my investment. There are few opportunities when you can recoup your initial investment in 6 months or less. And being part of a new revolution sealed the deal for me.</p>
<p>Later, when I realized I could support those in need and my favorite non-profits, I knew I was onto something big.</p>
<p><em>I hope you found this post beneficial. None of the text in this post is investment advice. Cryptocurrencies and new movements may  <a target="_blank" href="https://www.bitcoininsider.org/article/116895/unknown-cryptocurrency-soared-164842-hours-only-crash-99">crash and burn overnight</a>. Weigh the risk-reward ratio for yourself rather than trusting me.</em></p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on  <a target="_blank" href="https://medium.com/geekculture/build-a-new-internet-and-make-passive-income-for-you-or-others-1d85793462ae">Medium</a></em></p>
<p><em>Photo by <a target="_blank" href="https://unsplash.com/@kajhinkson">Kyle Hinkson</a> on <a target="_blank" href="https://unsplash.com">Unsplash</a></em></p>
]]></content:encoded></item><item><title><![CDATA[What is Cybersecurity? (An anecdote about a JSON Web Token.)]]></title><description><![CDATA["Is a web app secure just because I use a JWT?"
That is a question I had when I first learned about them.
Learning is important.
I was impressed with how well designed were JWT, OIDC, SAML, and modern Identity Provider (IdP) solutions. The quality of...]]></description><link>https://miguelacallesmba.com/what-is-cybersecurity-an-anecdote-about-a-json-web-token</link><guid isPermaLink="true">https://miguelacallesmba.com/what-is-cybersecurity-an-anecdote-about-a-json-web-token</guid><category><![CDATA[#cybersecurity]]></category><category><![CDATA[JWT]]></category><category><![CDATA[Security]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Tue, 25 May 2021 17:28:01 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1621963594908/tSLyctQGM.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>"Is a web app secure just because I use a JWT?"</p>
<p>That is a question I had when I first learned about them.</p>
<h2 id="heading-learning-is-important">Learning is important.</h2>
<p>I was impressed with how well designed were JWT, OIDC, SAML, and modern Identity Provider (IdP) solutions. The quality of the design I read about in the Request for Comments (RFCs) was impressive. Yet even after reading the RFCs and watching tutorials, something was still nagging at me.</p>
<h2 id="heading-test-assumptions-and-concerns">Test assumptions and concerns.</h2>
<p>One day I decided to log into one web application and copied the JWT using the Chrome developer tools.</p>
<p>I went to another web application and opened the Chrome developer tools. I added the other site's JWT token and refreshed the page.</p>
<h2 id="heading-a-surprise-outcome">A surprise outcome.</h2>
<p>I logged in!</p>
<p>I had an active login, but there were multiple errors and missing data within the different views.</p>
<p>After some investigation, I realized the APIs validated the JWTs, but the web application client did not.</p>
<h2 id="heading-what-is-cybersecurity">What is cybersecurity?</h2>
<p>Even well-designed solutions and technologies require secure implementation.</p>
<p>When something is nagging at us, or we suspect a potential flaw, we should take the time to investigate and test it.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on <a target="_blank" href="https://www.patreon.com/posts/51565746">Patreon</a></em></p>
<p><em>Photo by <a target="_blank" href="https://unsplash.com/@zisun_word">ZSun Fu</a> on <a target="_blank" href="https://unsplash.com">Unsplash</a></em></p>
]]></content:encoded></item><item><title><![CDATA[What is Cybersecurity? (An anecdote about a doorknob)]]></title><description><![CDATA[Cybersecurity, in its essence, is pretty simple: identify risks and mitigate them. Identifying risks is finding weaknesses that leave you vulnerable. This anecdote will explain what I mean.
Replacing a doorknob.
I needed to replace a doorknob. We had...]]></description><link>https://miguelacallesmba.com/what-is-cybersecurity-an-anecdote-about-a-doorknob</link><guid isPermaLink="true">https://miguelacallesmba.com/what-is-cybersecurity-an-anecdote-about-a-doorknob</guid><category><![CDATA[#cybersecurity]]></category><category><![CDATA[Story]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Wed, 21 Apr 2021 03:44:27 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1618976532588/EqNlWEHP3.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Cybersecurity, in its essence, is pretty simple: identify risks and mitigate them. Identifying risks is finding weaknesses that leave you vulnerable. This anecdote will explain what I mean.</p>
<h2 id="heading-replacing-a-doorknob">Replacing a doorknob.</h2>
<p>I needed to replace a doorknob. We had been living in our home with the original locks. I was concerned the previous owner may have kept a copy of the key and might want to enter our premises uninvited.</p>
<p><em>I performed a risk assessment.</em></p>
<p>I bought a new doorknob manufactured from a reputable brand, and that looked pretty. I trusted this brand to provide more than adequate protection. I felt that paying extra was worth the extra security.</p>
<p><em>I identified the mitigation.</em></p>
<p>It was time to improve my home's security. I removed the old doorknob and installed the new one.</p>
<p><em>I implemented the mitigation.</em></p>
<p>I felt pretty good until...</p>
<p>My gut performed an unconscious risk assessment. I started to feel uneasy. I began to think, "Did I do it correctly?"</p>
<p><em>My conscious mind realized I needed to update my risk assessment.</em></p>
<p>You might think this is a ridiculous question. Of course, a new doorknob would prevent the previous owner from entering uninvited.
This might be the logical conclusion, so why bother with another risk assessment?</p>
<p>I decided to stand outside, close the door, and kick the door.
To my surprise, the door opened wide. Huh?!</p>
<p>I installed the doorknob backward!!</p>
<p><em>The mitigation was unsatisfactory.</em></p>
<p>I fixed the doorknob, closed the door, and kicked hard (several times). The door remained closed.</p>
<p><em>I addressed the findings from both the old and new risk assessments.</em></p>
<h2 id="heading-so-what-is-cybersecurity">So what is Cybersecurity?</h2>
<p>Think about what could go wrong, find ways to address them, make the changes, and repeat the process.</p>
<p>When you implement a fix, make sure to test that it works too.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on <a target="_blank" href="https://www.patreon.com/posts/50037219">Patreon</a></em></p>
<p><em>Photo by <a target="_blank" href="https://unsplash.com/@pechka">Dima Pechurin</a> on <a target="_blank" href="https://unsplash.com">Unsplash</a></em></p>
]]></content:encoded></item><item><title><![CDATA[How to write to CXOs and supervisors]]></title><description><![CDATA[This post will teach you how to write to high-level business people.
Over ten years ago I enrolled into an MBA where I learned how to write to high-level business people. I have refining what I learned since then. I am sharing what I have learned to ...]]></description><link>https://miguelacallesmba.com/how-to-write-to-cxos-and-supervisors</link><guid isPermaLink="true">https://miguelacallesmba.com/how-to-write-to-cxos-and-supervisors</guid><category><![CDATA[Career]]></category><category><![CDATA[writing]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Wed, 31 Mar 2021 07:00:00 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1616876021639/Vj6sXsFlp.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>This post will teach you how to write to high-level business people.</p>
<p>Over ten years ago I enrolled into an MBA where I learned how to write to high-level business people. I have refining what I learned since then. I am sharing what I have learned to save you the cost of an MBA and over a decade of practice.</p>
<h2 id="heading-leaders-are-busy-get-to-the-point">Leaders are busy. Get to the point.</h2>
<p>Bosses, supervisors, directors, and CXOs are busy with many responsibilities. We should aim to take up less of their time and give them actionable information to make decisions faster.</p>
<p>Leaders should read your message and get all the necessary information in less than a paragraph. That is difficult to do after. With practice, it becomes easier.</p>
<p>Leaders should be able to respond quickly too. Your questions to them should allow them to reply with "yes," "no," "why?" or a concise sentence. A faster response will enable them to move onto the next item on their busy day.</p>
<h2 id="heading-two-requests-to-a-leader">Two requests to a leader.</h2>
<p>We will review two requests from an engineer to a CEO. The engineer was tasked to investigate a "thing" and find the best choice to get it done. The engineer will present the best options so the CEO can make the final decision.</p>
<p>Here are two examples: a not-so-good one and a better one.</p>
<h3 id="heading-a-not-so-good-example">A not-so-good example.</h3>
<p>Dear CEO,</p>
<p>I have spent the past few weeks researching this "thing." I have done multiple assessments, spoken with many vendors, and conducted various tests. I have narrowed down the final choices for the "thing."</p>
<p>The first choice is not as good because it requires "widget X" and will take several months to implement. But it will save us 5% per month after two years. Read the attached document for the rest of the details.</p>
<p>The second choice is better. It does not require any widgets, but it will still take several weeks to implement. It will only save us 4% per month after one year. Read the attached document for the rest of the details.</p>
<p>The third choice is the best in my opinion. It does require "widget Y," but it will only take a few days to implement. There are no cost savings, but the savings in the implementation time make up the difference. Read the attached document for the rest of the details.</p>
<p>Please let us know which choice you prefer.</p>
<h3 id="heading-a-better-example">A better example.</h3>
<p>Dear CEO,</p>
<p>I have narrowed down the final choice for the "thing." I recommend the first choice because we can implement it within days and the cost is comparable to the other two choices. The other two choices take several weeks to months to implement and only save up to 5% after one or two years.</p>
<p>Do I have your approval to buy the first choice?</p>
<h2 id="heading-deconstructing-the-two-requests">Deconstructing the two requests.</h2>
<p>The first request is very long and lengthy. The engineer explains his task even though the CEO already knows it.  This persons also brags about the amount of work invested. This person then proceeds to explain each choice in one paragraph. The leader does not learn about the best option until the end of the email.</p>
<p>The second request is only one paragraph. The engineer states the outcome in the first sentence and the recommended choice in the second sentence, and explains why the other two options were not as good in the third sentence. This person then asks a question that will lead to a yes/no response, or a request for additional information or a meeting.</p>
<p>The second request achieves in three sentences in what took four paragraphs in the first request.</p>
<h2 id="heading-what-about-the-details">What about the details?</h2>
<p>As an engineer, I want to provide all the information and details about my analysis. Most engineers I know take pride in their work and get excited to share it. This does not mean we need to share all the details. We need to resist getting into all the details and get right to the point.</p>
<p>If our boss asks us to find the best widget, we return with the best one. If our boss asks us to discover why something failed, we present the most likely reasons. We share why as succinctly as possible.</p>
<h2 id="heading-conclusion">Conclusion.</h2>
<p>Getting to the point may be a difficult thing to do at first. We can fight the urge to share all the details by writing them down in a document. That document will be available to anyone who wants to know your processes, data, and findings. When it comes to communicating with others, present the outcome in one paragraph, in 30 seconds, or on one slide (depending on which medium you choose).</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on <a target="_blank" href="https://www.patreon.com/posts/49282127">Patreon</a></em></p>
<p><em>Photo by <a target="_blank" href="https://unsplash.com/@wocintechchat">Christina @ wocintechchat.com</a> on <a target="_blank" href="https://unsplash.com">Unsplash</a></em></p>
]]></content:encoded></item><item><title><![CDATA[Donate cryptocurrency to non-profits by browsing the web with Brave Browser]]></title><description><![CDATA[We can support a school, a religious organization, and any non-profit by simply doing what we already do: browsing the web. Imagine that every time we do anything on a web browser, we support our favorite non-profits. We can achieve it through crypto...]]></description><link>https://miguelacallesmba.com/donate-cryptocurrency-via-web-browsing</link><guid isPermaLink="true">https://miguelacallesmba.com/donate-cryptocurrency-via-web-browsing</guid><category><![CDATA[Cryptocurrency]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Sat, 27 Mar 2021 21:39:31 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1616880937167/lB9iQ_MlL.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>We can support a school, a religious organization, and any non-profit by simply doing what we already do: browsing the web. Imagine that every time we do anything on a web browser, we support our favorite non-profits. We can achieve it through cryptocurrencies.</p>
<h2 id="heading-how-it-works">How it works</h2>
<p>We probably spend at least one to two hours using a web browser for personal reasons. Some of us probably use a web browser six to eight hours a day for work reasons. Even if we can earn five cents per hour when using a browser, we can donate at least $1 per month. That becomes $12 per year that we can donate by doing what we already do.</p>
<h3 id="heading-introducing-the-brave-browser">Introducing the Brave browser</h3>
<p>The Brave browser allows us to do this. The browser is based on the Chromium browser. This is the same base that the Google Chrome browser uses. Anyone using Google Chrome would feel at home with the Brave browser.</p>
<p>The Brave browser was designed with privacy and speed in mind. It blocks trackers, ads, and other things that invade our privacy. As a result, web pages load faster.</p>
<h3 id="heading-introducing-brave-rewards">Introducing Brave Rewards</h3>
<p>To fund their development, Brave has a reward program. They anonymously serve ads as browser notifications. Whenever we get an ad notification, we are compensated with an amount of the <a target="_blank" href="https://coinmarketcap.com/currencies/basic-attention-token/">Basic Attention Token (BAT)</a> cryptocurrency. We can choose to exchange BAT for a fiat currency (e.g., USD), hold them until they appreciate in value, or spend them on a service that uses BAT.</p>
<p>We can also choose to contribute BAT to any Brave Creator. Brave Creators earn BAT whenever someone visits one of their websites, gets a tip, or receives a designated monthly contribution. A non-profit can start earning BAT when it registers as a Brave Creator, and Brave browser users contribute BAT.</p>
<h2 id="heading-doing-our-part">Doing our part</h2>
<p>We need to take some steps to start contributing BAT to a non-profit. We will review how to set up the Brave Browser, opting in for Brave Rewards, and setting up monthly BAT contributions.</p>
<p>We download the Brave browser from <a target="_blank" href="https://brave.com">https://brave.com</a>. We run the installer as we typically would on our operating system.</p>
<p>We are given the option to do a welcome tour which we can skip if desired.</p>
<p>We are also prompted to enable Brave Rewards. Once enabled, we can access the Brave Rewards settings by clicking the Brave Rewards icon to the address bar's right. We can also type <code>brave://rewards/</code> into the address bar.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616878318436/OC8WCSukd.png" alt="Brave Rewards icon" /></p>
<p>We click the Brave Rewards icon and click the "Rewards Settings" link.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616878415979/0oTxtDEbv.png" alt="Brave Rewards settings" /></p>
<p>We go to the Ads section and click the ads settings button.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616878492383/IqoojzE3f.png" alt="Brave Rewards ads settings" /></p>
<p>We configure the settings per our preferences. (I chose to get the maximum number of ads.)</p>
<p>We can enable Auto-Contribute if we want to donate BAT to any Brave Creator website we visit. We are leaving this off so we can control how much BAT we donate and to whom.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616878672734/EEXlK6RKX.png" alt="Brave Rewards auto-contribute" /></p>
<p>We need to visit the Brave Creator's website to enable monthly contributions or give tips. For illustration purposes, we will use MiguelACallesMBA.com as an example.</p>
<p>When we visit a Brave Creator's website, we will see a checkmark on the Brave Rewards icon. When we click it, it will allow us to set up the monthly contribution or give tips. We do either or both, depending on our preferences.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616879018587/oZB-FzYC2.png" alt="An example of a Brave Creator web site" /></p>
<p><em>We will see a "Verify Wallet" status on the Brave Rewards dropdown. We may safely ignore this if we plan to donate all your BAT. If we plan to use any of the BAT for other purposes, we will need to create an account on <a target="_blank" href="https://uphold.com">Uphold.com</a> and connect it to Brave Rewards.</em></p>
<h2 id="heading-the-non-profits-part">The non-profit's part</h2>
<p>We must encourage a non-profit to become a Brave Creator and have an Uphold wallet for all this to work. They may be hesitant to accept cryptocurrency donations. We must help them understand this is similar to receiving other non-cash and asset donations (e.g., stocks, clothes, household items, and trusts). The BAT cryptocurrency is easily exchanged to a fiat currency (e.g., USD). They might also increase the donation's size if they hold it until it appreciates in value---although there is no guarantee that it will. We will review the process to become a Brave Creator.</p>
<p>The non-profit should first sign up at Uphold.com and <a target="_blank" href="https://support.uphold.com/hc/en-us/articles/207487326-How-do-I-apply-for-an-Uphold-business-account-and-what-are-the-benefits-">create a business account</a>. This step is important because they will be unable to convert BAT to a fiat currency without a valid Uphold wallet.</p>
<p>After they have a valid Uphold account, they <a target="_blank" href="https://creators.brave.com/">sign up as Brave Creator</a>. Once they create their Brave Creator account, they can link their Uphold wallet.</p>
<p>Now that they can receive BAT funds, they must create a channel to receive contributions and tips.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616879720493/FyKLtbgP0.png" alt="Adding a new Brave Creator channel" /></p>
<p>A channel can be a website, YouTube channel, Twitch channel, Twitter account, Vimeo channel, Reddit channel, and GitHub account. These are the channel types available at the time of this writing.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616879832270/h5b5S74l7.png" alt="Brave Creator channels" /></p>
<p>We should encourage them to enable as many channels as they have available.</p>
<p>Each channel type will require verifying ownership of the channel. For example, a website has two verification options.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616879940680/fMsKtdEzd.png" alt="Brave Creator web site verification options" /></p>
<p>Once verified, they can choose to enable the ability to serve ads. This possibility allows them to earn additional BAT from visitors who visit their channel.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1616880058127/fK7p4hQ5V.png" alt="Enabling ads on a Brave Creator web site" /></p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>We can use Brave Rewards to earn the Basic Attention Token (BAT) cryptocurrency while browsing the web using the Brave browser. We can donate BAT to our favorite non-profits when they enroll as a Brave Creator. The non-profits can convert BAT to a fiat currency (e.g., USD) or hold it until it appreciates in value.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on <a target="_blank" href="https://miguelacallesmba.com/donate-cryptocurrency-via-web-browsing">MiguelACallesMBA.com</a></em></p>
<p><em>Photo by <a target="_blank" href="https://unsplash.com/@kellysikkema">Kelly Sikkema</a> on  <a target="_blank" href="https://unsplash.com">Unsplash</a></em></p>
]]></content:encoded></item><item><title><![CDATA[How to use CryptoJS and Cookies to Work with Secrets in Postman]]></title><description><![CDATA[In my previous article, we explored how to use cookies in Postman to store your secrets. Depending on your security requirements, you may need to use cryptography. This is where CryptoJS can help.
Script to Generate an Encrypted Secret
We can use a l...]]></description><link>https://miguelacallesmba.com/postman-secrets-cookies-cryptojs</link><guid isPermaLink="true">https://miguelacallesmba.com/postman-secrets-cookies-cryptojs</guid><category><![CDATA[Security]]></category><category><![CDATA[APIs]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Thu, 04 Feb 2021 21:58:47 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1612475887354/JBmOHUFA2.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>In my previous article, we explored <a target="_blank" href="https://miguelacallesmba.com/how-to-use-cookies-to-store-secrets-in-postman">how to use cookies in Postman to store your secrets</a>. Depending on your security requirements, you may need to use cryptography. This is where CryptoJS can help.</p>
<h2 id="heading-script-to-generate-an-encrypted-secret">Script to Generate an Encrypted Secret</h2>
<p>We can use a local Node.js script with the CryptoJS library to encrypt the secret. The example below shows how we will encrypt an API key.</p>
<pre><code class="lang-js"><span class="hljs-keyword">const</span> CryptoJS = <span class="hljs-built_in">require</span>(<span class="hljs-string">'crypto-js'</span>);
<span class="hljs-keyword">const</span> { <span class="hljs-attr">API_KEY</span>: apiKey, <span class="hljs-attr">SECRET_KEY</span>: secretKey } = process.env;
<span class="hljs-keyword">const</span> encryptedText = CryptoJS.AES.encrypt(apiKey, secretKey).toString();
<span class="hljs-built_in">console</span>.log(<span class="hljs-string">'encryptedText:'</span>, encryptedText);
</code></pre>
<p>We set the API key and secret key (used to encrypt the API key) as environment variables. That way we do not hardcode data into our script.</p>
<h2 id="heading-using-the-encrypted-secret-and-the-secret-key-in-postman">Using the Encrypted Secret and the Secret Key in Postman</h2>
<p>We will store the secret key as a cookie to avoid sharing the value, and will store the encrypted API key as an environment variable.</p>
<p>We whitelist a cookie domain.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1612475009265/tOFTO98PA.png" alt="Whitelisting the cookie domain" /></p>
<p>We create a cookie to store the secret key.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1612475087385/FJ5CD_YXx.png" alt="Cookie with the secret key" /></p>
<p>We create an environment variable that has the encrypted API key.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1612475271432/yOKuj1YAw.png" alt="Environment variable with the encrypted API key" /></p>
<p>We create a pre-request script to get the secret key from the cookie, decrypt the encrypted API key from the environment variable, and set a temporary variable (Postman Sessions) with the plaintext API key.</p>
<pre><code class="lang-js"><span class="hljs-comment">// https://postman-quick-reference-guide.readthedocs.io/en/latest/libraries.html</span>
<span class="hljs-keyword">const</span> cookieJar = pm.cookies.jar();
<span class="hljs-keyword">const</span> sessionVarName = <span class="hljs-string">"xApiKey"</span>;
<span class="hljs-keyword">const</span> cookieName = <span class="hljs-string">"secretKey"</span>;
<span class="hljs-keyword">const</span> domain = <span class="hljs-string">"postman.galaxy.demo"</span>;
cookieJar.get(domain, cookieName, <span class="hljs-function">(<span class="hljs-params">error, secretKey</span>) =&gt;</span> {
  <span class="hljs-keyword">if</span> (error) {
    <span class="hljs-built_in">console</span>.error(error);
    pm.variables.set(sessionVarName, <span class="hljs-string">"error"</span>);
  }
  <span class="hljs-keyword">if</span> (secretKey) {
    <span class="hljs-comment">// decryption</span>
    <span class="hljs-built_in">console</span>.log(<span class="hljs-string">'secretKey'</span>, secretKey);
    <span class="hljs-keyword">const</span> xApiKeyEnc = pm.environment.get(<span class="hljs-string">'x-api-key-enc'</span>);
    <span class="hljs-built_in">console</span>.log(<span class="hljs-string">'xApiKeyEnc'</span>, xApiKeyEnc);
    <span class="hljs-keyword">const</span> xApiKey = CryptoJS.AES.decrypt(xApiKeyEnc, secretKey).toString(CryptoJS.enc.Utf8);
    <span class="hljs-built_in">console</span>.log(<span class="hljs-string">'xApiKey'</span>, xApiKey);
    pm.variables.set(sessionVarName, xApiKey);
  } <span class="hljs-keyword">else</span> {
    <span class="hljs-built_in">console</span>.error(<span class="hljs-string">"Cookie is missing"</span>)
    pm.variables.set(sessionVarName, <span class="hljs-string">"missing"</span>);
  }
});
</code></pre>
<p>We write a test to explicitly delete the <code>xApiKey</code> variable after the request completes.</p>
<pre><code class="lang-js">pm.variables.unset(<span class="hljs-string">"xApiKey"</span>);
</code></pre>
<p>We can use the <code>xApiKey</code> variable to use the plaintext API key.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1612475396159/UDpIAmby6.png" alt="Using the Postman Sessions variable" /></p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>By using cookies, we can use a secret key while avoiding sharing it. By using CryptoJS, we can store encrypted data in an environment variable, decrypt it, and use the plaintext (i.e., decrypted) data only during the request execution.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Photo by <a target="_blank" href="https://unsplash.com/@foodess">Food Photographer | Jennifer Pallian</a> on <a target="_blank" href="https://unsplash.com/s/photos/cookies">Unsplash</a></em></p>
]]></content:encoded></item><item><title><![CDATA[Using Many Email Addresses to Reduce Your Cybersecurity Risk]]></title><description><![CDATA[The days of having one email address are over. We are putting all our eggs in one basket by having one address. If someone hacks that account, we could be in big trouble.
Guessing An Email Address
Guessing an email address can be easy. We can guess a...]]></description><link>https://miguelacallesmba.com/using-many-email-addresses-to-reduce-your-cybersecurity-risk</link><guid isPermaLink="true">https://miguelacallesmba.com/using-many-email-addresses-to-reduce-your-cybersecurity-risk</guid><category><![CDATA[Security]]></category><category><![CDATA[email]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Sun, 10 Jan 2021 21:10:54 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1610312760811/flAiYtQdy.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>The days of having one email address are over. We are putting all our eggs in one basket by having one address. If someone hacks that account, we could be in big trouble.</p>
<h2 id="heading-guessing-an-email-address">Guessing An Email Address</h2>
<p>Guessing an email address can be easy. We can guess an email address by trying any of the following:</p>
<ul>
<li><code>FirstInitialLastName@gmail.com</code></li>
<li><code>FirstNameLastName@gmail.com</code></li>
<li><code>FirstName.LastName@gmail.com</code></li>
</ul>
<p>What is the chance you have this email address?</p>
<h2 id="heading-social-media-accounts">Social Media Accounts</h2>
<p>We often post too much information on social media accounts. We post our name, location, recent activity, links, and more. Someone can use this information to deduce information. They can guess an email address, figure out <a target="_blank" href="https://www.secjuice.com/advice-on-answering-security-questions/">security questions</a>, or even take it over. We are making it easier for someone to guess our email address.</p>
<h2 id="heading-taking-advantage-of-email-tags">Taking Advantage of Email Tags</h2>
<p>We can be in big trouble if our important accounts use the guessable address. We can reduce this exposure by using email tags. We can sign up to a bank website with the email FirstName.LastName+SomeUniqueTag@gmail.com. Many <a target="_blank" href="https://www.cs.rutgers.edu/~watrous/plus-signs-in-email-addresses.html">email providers</a> and online accounts support this capability.</p>
<h2 id="heading-taking-advantage-of-many-addresses">Taking Advantage of Many Addresses</h2>
<p>Services like Gmail make having many addresses cost-effective. We can have a different email address for a different purpose.</p>
<ul>
<li><code>FirstName.LastName@gmail.com</code> for emailing friends and family.</li>
<li><code>FirstName.LastName.DesiredJobTitle@gmail.com</code> for job hunting and resumes.</li>
<li><code>FunPseudoNameOrHandle@gmail.com</code> for non-important accounts.</li>
<li><code>SeriousPseudoNameOrHandle@gmail.com</code> for important accounts.</li>
<li><code>AnotherSeriousPseudoNameOrHandle@gmail.com</code> for your password manager.</li>
</ul>
<p>Make sure you use a "PseudoNameOrHandle" that someone cannot guess.</p>
<p>You may also use email tags to make it more difficult to guess the email address. For example, using a SeriousPseudoNameOrHandle+UniqueTag@gmail.com convention per account.</p>
<h2 id="heading-has-your-email-address-been-leaked">Has Your Email Address Been Leaked?</h2>
<p>You should check whether your email address has been leaked. You can use <a target="_blank" href="https://haveibeenpwned.com/">Have I Been Pwned</a> to check all your email addresses. Create a new email address and start moving your accounts to that email address if you have been Pwned.</p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>Using different email addresses as a cybersecurity strategy can reduce our risk. But make sure to follow good security hygiene. Use a strong, unique password for each account. Enable two-factor/multi-factor authentication. Update your passwords regularly. Also, check all those email accounts to avoid missing important messages.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on <a target="_blank" href="https://www.secjuice.com/using-many-email-addresses-to-reduce-cybersecurity-risk/">Secjuice.com</a></em></p>
<p><em>Photo by <a target="_blank" href="https://www.behance.net/przemyslawkruk">Przemyslaw Kruk</a> on  <a target="_blank" href="https://www.behance.net/">Behance</a></em></p>
]]></content:encoded></item><item><title><![CDATA[Finding Winning Stocks with Web Scrapers, and Serverless (AWS Lambda and DynamoDB)]]></title><description><![CDATA[A few friends and I chat about stocks, share ideas, and encourage each other. A few months ago, I realized we needed some automation to help us find winners. I chose to use a serverless solution to build this system.
There are many good stocks and fi...]]></description><link>https://miguelacallesmba.com/finding-winning-stocks-with-serverless</link><guid isPermaLink="true">https://miguelacallesmba.com/finding-winning-stocks-with-serverless</guid><category><![CDATA[serverless]]></category><category><![CDATA[AWS]]></category><category><![CDATA[web scraping]]></category><category><![CDATA[Python]]></category><category><![CDATA[aws lambda]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Mon, 04 Jan 2021 00:11:11 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1609719061543/dlnbXwzLp.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>A few friends and I chat about stocks, share ideas, and encourage each other. A few months ago, I realized we needed some automation to help us find winners. I chose to use a serverless solution to build this system.</p>
<p>There are many good stocks and finding them takes time. We can find them by reading articles, using stock tools, getting tips from Twitter, and many other ways. With so many ways to find stock candidates, we needed to define the process.</p>
<h2 id="heading-finding-a-screener">Finding a Screener</h2>
<p>We decided FinViz.com was a good source to start our automation. One of our team members is a good stock analyst. He created a <a target="_blank" href="https://www.finviz.com/screener.ashx?v=351&amp;f=cap_smallover,fa_eps5years_pos,fa_sales5years_pos,ind_stocksonly,sh_price_o2,sh_relvol_o2,ta_changeopen_u1,ta_perf_dup,ta_perf2_52wup&amp;ft=4&amp;o=-relativevolume">screener</a> that we used for a long while.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1609717059726/J9zYrSu-S.png" alt="finviz-screener.png" /></p>
<p><em>Example FinViz Screener</em></p>
<h2 id="heading-creating-a-web-scraper">Creating a Web Scraper</h2>
<p>After a while, we noticed we were forgetting to check this screener. That is when automation became handy. I wrote a Python web scraper using BeautifulSoup to get the top 10 stock symbols from the screener.</p>
<pre><code class="lang-python"><span class="hljs-keyword">import</span> requests
<span class="hljs-keyword">from</span> bs4 <span class="hljs-keyword">import</span> BeautifulSoup

FINVIZ_BASE = <span class="hljs-string">"https://finviz.com"</span>
FINVIZ_PATH = os.environ.get(<span class="hljs-string">'FINVIZ_PATH'</span>)
FINVIZ_DATA = {}
FINVIZ_HEADERS = {
    <span class="hljs-string">'User-Agent'</span>: <span class="hljs-string">'My Trading App/0.0.1'</span>
}

response = requests.get(
    <span class="hljs-string">f'<span class="hljs-subst">{FINVIZ_BASE}</span><span class="hljs-subst">{FINVIZ_PATH}</span>'</span>,
    headers=FINVIZ_HEADERS,
    data=FINVIZ_DATA
)

soup = BeautifulSoup(response.text.encode(<span class="hljs-string">'utf8'</span>), <span class="hljs-string">'html.parser'</span>)

<span class="hljs-comment">## look for symbols</span>
<span class="hljs-keyword">for</span> link <span class="hljs-keyword">in</span> soup.find_all(<span class="hljs-string">'a'</span>):
    <span class="hljs-keyword">if</span> link.get(<span class="hljs-string">'href'</span>).startswith(<span class="hljs-string">'quote.ashx?t='</span>):
        symbol = link.string
        <span class="hljs-keyword">if</span> symbol:
            <span class="hljs-comment">## assumes this html code</span>
            <span class="hljs-comment">## &lt;a class="tab-link" href="quote.ashx?t=TWTR&amp;amp;ty=c&amp;amp;p=d&amp;amp;b=1"&gt;TWTR&lt;/a&gt;</span>
            symbols.append(symbol)
</code></pre>
<p>I needed a way to run this web scraper on a timer. I could have set up a server to run the Python code on a CRON, but I did not want to maintain the server. I decided to use a serverless solution to reduce maintenance and keep my costs low.</p>
<p>I set up an AWS Lambda function with a Python runtime, and deployed it using <a target="_blank" href="https://miguelacallesmba.com/aws-cdk-vs-serverless-framework">AWS CDK</a>. I configured CloudWatch rules to set up a CRON to trigger the Lambda function. Now the web scraper runs per the schedule.</p>
<h2 id="heading-posting-to-slack">Posting to Slack</h2>
<p>We were already using Slack to chat, so it was the ideal medium to post the top ten symbols. I created a Slack app that posted the findings to an #alerts channel and the #general channel. The #alert channel posts had detailed information (e.g., chart images). The #general channel posts had the summary information. We did this to not overwhelm the discussion in the #general channel.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1609716913629/ZcZX-_R8v.png" alt="alert-channel.png" /></p>
<p><em>Example of the #alert channel post.</em></p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1609716929200/HTIR0XVD8.png" alt="general-channel.png" /></p>
<p><em>Example of the #general channel post.</em></p>
<h2 id="heading-creating-stats">Creating stats</h2>
<p>As you might have guessed, it became difficult to see patterns without some type of stats. We had good intel, but how do we decide which stocks to pick without some type of histogram.</p>
<p>We wrote the stock symbols to a DynamoDB table, and the date when they appeared in the alert.</p>
<pre><code class="lang-python"><span class="hljs-keyword">import</span> boto3

STATS_TABLE_NAME = os.environ.get(<span class="hljs-string">'STATS_TABLE_NAME'</span>)
STATS_TTL_NAME = os.environ.get(<span class="hljs-string">'STATS_TTL_NAME'</span>)
STATS_TTL_DAYS = int(os.environ.get(<span class="hljs-string">'STATS_TTL_DAYS'</span>)

client = boto3.client(<span class="hljs-string">'dynamodb'</span>)

<span class="hljs-keyword">for</span> symbol <span class="hljs-keyword">in</span> symbols:
    client.update_item(
        TableName=STATS_TABLE_NAME,
        Key={
            <span class="hljs-string">'PK'</span>: {
                <span class="hljs-string">'S'</span>: symbol,
            },
            <span class="hljs-string">'SK'</span>: {
                <span class="hljs-string">'S'</span>: <span class="hljs-string">f'#<span class="hljs-subst">{sk_prefix}</span>#'</span>,
            },
        },
        AttributeUpdates={
            STATS_TTL_NAME: {
                <span class="hljs-string">'Value'</span>: {
                   <span class="hljs-string">'N'</span>: <span class="hljs-string">f'<span class="hljs-subst">{ttl}</span>'</span>
                },
                <span class="hljs-string">'Action'</span>: <span class="hljs-string">'PUT'</span>,
            },
            scan_name: {
                <span class="hljs-string">'Value'</span>: {
                   <span class="hljs-string">'BOOL'</span>: <span class="hljs-literal">True</span>,
                },
                <span class="hljs-string">'Action'</span>: <span class="hljs-string">'PUT'</span>,
            },
        },
    )
</code></pre>
<p>We then created another Lambda function to post a text-based histogram.</p>
<p><img src="https://cdn.hashnode.com/res/hashnode/image/upload/v1609718020558/T19_VGMZu.png" alt="stats-post.png" /></p>
<p><em>Example histogram post to the #general channel.</em></p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>With a little code we implemented automation to our manual investment process. We were able to extend this approach to scrape different investment sources. Furthermore, it costs $0.00 per month by taking advantage of the serverless capabilities in the <a target="_blank" href="https://aws.amazon.com/free/">AWS free tier</a>.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Disclaimer: This is NOT investment advice.</em></p>
<p><em>Photo by  <a target="_blank" href="https://unsplash.com/@firmbee">William Iven</a>  on  <a target="_blank" href="https://unsplash.com/s/photos/investor">Unsplash</a> </em></p>
]]></content:encoded></item><item><title><![CDATA[Serverless Best Practices on AWS]]></title><description><![CDATA[Do your serverless deployments go like this?
It’s so easy to quickly deploy serverless resources. Because of this, we should follow best practices to protect our resources, applications, and cloud service provider accounts. Here are some best practic...]]></description><link>https://miguelacallesmba.com/serverless-best-practices-on-aws</link><guid isPermaLink="true">https://miguelacallesmba.com/serverless-best-practices-on-aws</guid><category><![CDATA[AWS]]></category><category><![CDATA[aws lambda]]></category><category><![CDATA[serverless]]></category><category><![CDATA[Security]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Sun, 13 Dec 2020 08:00:00 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1608849886835/lgtZp_Dt1.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p><img src="https://miro.medium.com/max/1400/1*3oTln9v58I3PNCWfWtgNrw.png" alt="Comic strip" /></p>
<p><em>Do your serverless deployments go like this?</em></p>
<p><span class="s ip iq ir is it iu iv iw ix gx">I</span>t’s so easy to quickly deploy serverless resources. Because of this, we should follow best practices to protect our resources, applications, and cloud service provider accounts. Here are some best practices for you to consider.</p>
<h2 id="heading-1-keep-functions-small">1. Keep Functions Small</h2>
<p>A serverless function should perform a specific function. Similar to a function or method in any code should do one thing (e.g., increment a counter, transform data, etc.), a serverless function show perform a logical function. For example, you would create one serverless function for validating a login, another for validating a login session, another for deactivating a login session. Having a serverless function perform more than one thing makes it vulnerable to bugs and makes it more difficult to maintain.</p>
<h2 id="heading-2-organize-functions-in-a-group-ie-use-microservices">2. Organize Functions in a Group (i.e., Use Microservices)</h2>
<p>Microservices allows us to contain data stores and functions into a maintainable group. The microservice will follow a contract that limits what it can and cannot do. For example, an account microservice will allow creating, updating, and deleting user accounts. This microservice should never modify any data outside of the user account data store. Furthermore, it will have a specific application programming interface (API). This allows other microservices to interact with the user account serverless functions in a consistent way without having to modify any of its user account data stores.</p>
<h2 id="heading-3-use-different-stacks-for-different-resources">3. Use Different Stacks for Different Resources</h2>
<p>AWS allows us to use CloudFormation stacks when deploying resources, and each Serverless Framework configuration deploys one CloudFormation stacks. We should aim to have one stack per resource type. For example, our user account microservice could have: database stack (to store account metadata in DynamoDB), identity provider (IdP) stack (to set up and maintain user sessions with Cognito), function stack (to deploy Lambda functions that provide the user account microservice API), and object store stack (to capture user account profile pictures in S3). This allows you to update a resource type without disrupting another resource type. For example, if you make an error in a functions stack deployment, your other stacks remain unaffected.</p>
<h2 id="heading-4-select-an-appropriate-api">4. Select an Appropriate API</h2>
<p>AWS offers three types of APIs: HTTP APIs, REST APIs, and GraphQL APIs. Each API has different benefits. HTTP APIs use API Gateway, are lightweight and natively support OpenID and OAuth. REST APIs use API Gateway, are fully featured REST APIs and provide additional security features. GraphQL APIs use AppSync, use a simple, but string query language, and integrates with DynamoDB databases and Elasticsearch Service data aggregator. API Gateway HTTP and REST APIs are best for interactions between APIs (or microservices) and providing external applications access to your applications API. AppSync GraphQL APIs are best between client and backend integrations within the same application (of course your client can still use an API Gateway API too.)</p>
<h2 id="heading-5-use-the-principle-of-least-privilege-in-your-serverless-functions">5. Use the Principle of Least Privilege in Your Serverless Functions</h2>
<p>All your resources should have the smallest set of IAM permissions. For example, a serverless function that reads a DynamoDB table should only have the read action for that one DynamoDB table. You should avoid using an asterisk “*” when defining privileges whenever possible. If you Lambda function is ever compromised and it uses asterisks such that every DynamoDB is accessible and every action is allowed, then a hacker can read and delete all database data.</p>
<h2 id="heading-6-set-up-a-cicd-pipeline">6. Set up a CI/CD Pipeline</h2>
<p>When you are first developing an application, deploying from the command line interface (CLI) is okay. Ideally before you get to deploying to production, you should be using a CI/CD pipeline to deploy your code. You can use services such as Serverless Framework Pro, GitHub Actions, SEED, and many others. CI part of the pipeline allows you to run linting checks, unit tests, and many other automated checks before allowing a pull request to merge. The CD part of the pipeline allows you to automatically deploy your serverless application whenever a PR is merged or a branch is updated. Using a CI/CD pipelines removes human error and introduces repeatability in your process.</p>
<h2 id="heading-7-monitor-your-application">7. Monitor Your Application</h2>
<p>We should use services, such as Dashbird, to monitor our serverless resources. There may be so many resources and they may be used so much that it would be difficult to manually check them for errors. Monitoring services can report health, longer executions, delays, and errors. Having a service that tells us when our serverless application and resources are having issues helps us to find and fix issues faster.</p>
<h2 id="heading-8-audit-your-cloud-provider-account-and-resources">8. Audit Your Cloud Provider Account and Resources</h2>
<p>In addition to monitoring, we want to audit. Monitoring tells when when something stops working or is having issues. Auditing tells us when our resources deviate from a known configuration or are improperly configured. We can use services such as AWS Config to create rules that audit our resources and their configurations. Config also has some predefined conformance packs that help us implement best practices. Here are some to consider:</p>
<ul>
<li>Operational Best Practices for Amazon DynamoDB</li>
<li>Operational Best Practices for Amazon S3</li>
<li>Operational Best Practices for AWS Identity And Access Management</li>
<li>Operational Best Practices for AWS Well-Architected Framework Reliability Pillar</li>
<li>Operational Best Practices for AWS Well-Architected Framework Security Pillar</li>
<li>Operational Best Practices for Serverless</li>
</ul>
<h2 id="heading-9-audit-your-software-dependencies">9. Audit Your Software Dependencies</h2>
<p>We also want to audit our software dependencies. Just because we no longer have a server, it does not mean we are free from “patching.” We want to make sure any software dependencies we define are up-to-date and have no known vulnerabilities. We can use services such as GitHub Dependabot and Snyk to keep us informed the software packages that need updating.</p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>Your mileage will vary depending on your business and technical requirements, the complexity of your application, and your cost and schedule. These best practices are aimed to guide in the right direction; they are based on the “<a target="_blank" href="https://ServerlessSecurityBook.com">Serverless Security</a>” book.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on <a target="_blank" href="https://medium.com/nerd-for-tech/serverless-best-practices-b547db36e4e3">Medium.com</a></em></p>
<p><em>Photo by <a target="_blank" href="https://unsplash.com/@rojekilian">Sarah Kilian</a> on <a target="_blank" href="https://unsplash.com/s/photos/mistake">Unsplash</a></em></p>
]]></content:encoded></item><item><title><![CDATA[Browser Extensions Can Have Malware: My Shock of “The Great Suspender” Chrome and Edge Extensions]]></title><description><![CDATA[For a couple of weeks, I have been pondering whether my browser extensions could be a source of vulnerabilities. It turns out they can!
A couple of days ago, I received a notification from the Microsoft Edge browser warning me about malware in one of...]]></description><link>https://miguelacallesmba.com/malware-in-browser-extensions</link><guid isPermaLink="true">https://miguelacallesmba.com/malware-in-browser-extensions</guid><category><![CDATA[Security]]></category><category><![CDATA[Browsers]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Sun, 22 Nov 2020 21:10:57 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1608757991422/bbfyu8zL5.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>For a couple of weeks, I have been pondering whether my browser extensions could be a source of vulnerabilities. It turns out they can!</p>
<p>A couple of days ago, I received a notification from the Microsoft Edge browser warning me about malware in one of my extensions: The Great Suspender.</p>
<img alt="Image for post" src="https://miro.medium.com/max/488/1*-waah2GdvbI84ZGZYyld5Q.png" />

<p>I started panicking, so I decided I would start researching this. I found the GitHub repository for The Great Suspender extension. I searched for “malware” in the open issues and surprisingly found a relevant issue.</p>
<p><a target="_blank" href="https://github.com/greatsuspender/thegreatsuspender/issues/1263"><strong>SECURITY: New maintainer is probably malicious</strong></a></p>
<p>Here are a couple of snippets from the issue that increased my concerns.</p>
<blockquote>
<p>On November 6th, <a target="_blank" href="http://twitter.com/lucasdf">@lucasdf</a> discovered a smoking gun that the new maintainer is malicious.</p>
<p>Using the chrome web store version of this extension, without disabling tracking, will execute code from an untrusted third-party on your computer, with the power to modify any and all websites that you see.</p>
</blockquote>
<p>I have been running anti-malware software and running scans daily, and there were no reports of malware. It occurred to me that anti-virus and anti-malware might only catch malware running on the machine.</p>
<p>Fortunately, I have been running the Malwarebytes browser extension for a few months. I hope this helped mitigate some of the issues, yet the malware might have been present since November 2019 (that more than one year ago at the time of this writing).</p>
<h2 id="heading-my-actions-steps">My actions steps</h2>
<p>I started to take action right away.</p>
<ul>
<li>I uninstalled the extension from the Microsoft Edge browser. Edge had already disabled it for me and no longer allows anyone to install it.</li>
<li>I uninstalled the extension from the Chrome browser. I also reported abuse since Chrome still allows anyone to install it.</li>
<li>I fully cleaned my browsers by clearing the all-time history, cache, etc.</li>
<li>I ran CCleaner to do a full cache clean on my machine.</li>
<li>I installed another anti-virus program and ran a full, deep scan just if my anti-malware program missed anything.</li>
<li>I started to changed passwords to my sensitive accounts.</li>
<li>I revisited my browser extension preferences, which I will discuss in further detail.</li>
</ul>
<p>From what I can tell, there is no breach. I hope it stays that way.</p>
<h2 id="heading-updated-browser-extension-preferences">Updated browser extension preferences</h2>
<p>I did the following to improve my browser extensions:</p>
<ul>
<li>I updated all the remaining extensions by visiting Manage Extensions, enabling Developer Mode, and performing an Update.</li>
</ul>
<img alt="Image for post" src="https://miro.medium.com/max/316/1*QHTJCv3yRWeDHhxWJpIhlA.png" />

<img alt="Image for post" src="https://miro.medium.com/max/320/1*rBwWEnRAjNKwSdh8zGkU4Q.png" />

<img alt="Image for post" src="https://miro.medium.com/max/184/1*YwB2V0sd9Ku6oPCW8cS3bw.png" />

<ul>
<li>I checked the extension permissions and realized I was giving the “keys of the kingdom” to all my extensions, so I put that to an end.</li>
</ul>
<img alt="Image for post" src="https://miro.medium.com/max/638/1*OM_FEP59sO3lW5TDcq3bcA.png" />

<ul>
<li>I visited each of the extension preferences, navigated to This Can Read and Change Site Data, and set the permission to When You Click the Extension. I implemented this setting to all extensions except those meant to “protect” me, such as the Malwarebytes Browser Guard extension. <em>Note: The screen capture below shows the restricted setting for illustration purposes.</em></li>
</ul>
<img alt="Image for post" src="https://miro.medium.com/max/1280/1*ewIrXnhjfa-dWsRYhAfr6Q.png" />

<p>Now, when I want to use an extension, I need to activate it.</p>
<img alt="Image for post" src="https://miro.medium.com/max/60/1*jSGFl_VLYzGqsGjB5GQD2Q.png" />

<p>The extension is currently disabled.</p>
<img alt="Image for post" src="https://miro.medium.com/max/630/1*cEfHxxZqbrsC8ESOypUhSA.png" />

<p>It is somewhat of an inconvenience. Yet, I still benefit from the extension only when I want to use it instead of when the extension wants to do something.</p>
<h2 id="heading-conclusion">Conclusion</h2>
<p>Decide whether it makes sense to install a browser extension, whether you can trust it, and how much of your data you are willing to give away.</p>
<p>Consider implementing the extension settings I showed above, and visit sensitive web sites (e.g., banking sites) using Incognito Mode.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on <a target="_blank" href="https://medium.com/nerd-for-tech/malware-in-browser-extensions-3805e8763dd5">Medium.com</a></em></p>
<p><em>Photo by <a target="_blank" href="https://unsplash.com/@jackson_893">Michael Geiger</a> on <a target="_blank" href="https://unsplash.com">Unsplash</a></em></p>
]]></content:encoded></item><item><title><![CDATA[Minimize How Long an Amazon Fire TV Device Can Listen To You]]></title><description><![CDATA[Recommendation for powering an Amazon FireTV Device
Amazon Fire TV devices are pretty nice, but there is the risk they listen to you. In this super short article, I will share how you can minimize the amount of time this device (or a similar device) ...]]></description><link>https://miguelacallesmba.com/minimize-how-long-an-amazon-fire-tv-device-can-listen-to-you</link><guid isPermaLink="true">https://miguelacallesmba.com/minimize-how-long-an-amazon-fire-tv-device-can-listen-to-you</guid><category><![CDATA[Security]]></category><category><![CDATA[Amazon]]></category><category><![CDATA[Internet of Things]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Wed, 11 Nov 2020 16:18:36 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1608850237549/fEqvWE7yG.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<img alt="Image for post" src="https://miro.medium.com/max/2560/0*oguHa6yHSROUgIYf" />

<p><em>Recommendation for powering an Amazon FireTV Device</em></p>
<p>Amazon Fire TV devices are pretty nice, but there is the risk they listen to you. In this super short article, I will share how you can minimize the amount of time this device (or a similar device) can listen to you.</p>
<ol>
<li>Buy an eco-friendly power strip that controls other outlets.</li>
<li>Connect your TV to the master (or control) outlet. This outlet will control when power is delivered to the dependant (or energy saving) outlets.</li>
<li>Connect your Fire TV (or similar device) to the dependant outlet.</li>
</ol>
<p>Now the Fire TV will only power on when you are watching TV.</p>
<p>BONUS #1: You can unplug the Fire TV USB port when you’re done watching and reconnect it when you want to watch. I suggest doing this because you may not always use your Fire TV when you watch TV. Surprisingly, I still use DVDs and Bluray discs.</p>
<p>BONUS #2: Connect your Fire TV to your router’s guest network instead of your main network. Configure the guest network not to have access to the main network. If the Fire TV ever gets hacked, the hacker will not have access to your main network.</p>
<p>I hope this helps you improve your home’s privacy and cybersecurity.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on <a target="_blank" href="https://medium.com/nerd-for-tech/minimize-how-long-an-amazon-firetv-device-can-listen-to-you-c971a2d49bd">Medium.com</a></em></p>
<p><em>Photo by <a target="_blank" href="https://unsplash.com/@jasonrosewell">Jason Rosewell</a> on <a target="_blank" href="https://unsplash.com/s/photos/microphone">Unsplash</a></em></p>
]]></content:encoded></item><item><title><![CDATA[Reducing the Attack Surface with Serverless Computing]]></title><description><![CDATA[Serverless environments are growing in popularity because they reduce overhead and costs. But do they necessarily improve your application’s security? Well for a start there are a lot fewer vulnerabilities to exploit. Let’s dig in and explore this a ...]]></description><link>https://miguelacallesmba.com/reducing-the-attack-surface-with-serverless-computing</link><guid isPermaLink="true">https://miguelacallesmba.com/reducing-the-attack-surface-with-serverless-computing</guid><category><![CDATA[serverless]]></category><category><![CDATA[AWS]]></category><category><![CDATA[Security]]></category><dc:creator><![CDATA[Miguel A. Calles MBA]]></dc:creator><pubDate>Thu, 29 Oct 2020 15:22:54 GMT</pubDate><enclosure url="https://cdn.hashnode.com/res/hashnode/image/upload/v1608827078409/rKQQuAAbd.jpeg" length="0" type="image/jpeg"/><content:encoded><![CDATA[<p>Serverless environments are growing in popularity because they reduce overhead and costs. But do they necessarily improve your application’s security? Well for a start there are a lot fewer vulnerabilities to exploit. Let’s dig in and explore this a little more.</p>
<p>Serverless environments allow you to build applications wit<span id="rmm"><span id="rmm">h</span></span>out needing to manage and use servers. They allow you to upload your code without worrying about how to configure a server, installing the runtime environment, applying patches, setting up the networking, and identifying all the other tasks needed to run said code. Sounds too good to be true? Wait, there’s more!</p>
<p>Serverless environments can potentially reduce your application’s attack surface. We will compare a traditional application’s attack surface against that one running in a serverless environment.</p>
<h1 id="heading-traditional-applications-attack-surface">Traditional Application’s Attack Surface</h1>
<p>Let’s suppose you have a web application you set up on traditional servers. This application has servers dedicated to running the web application code and other servers running the database. These servers are running in the same subnet somewhere, which could be in your own facilities or in a cloud provider. The application and web servers are configured to communicate with each other.</p>
<p>They run the same type and version of an operating system, a specific version of a software runtime, and a particular version of the database. Now that we have established the application’s components, we can proceed to identify the attack surface. The attack surface is the accumulation of all known and unknown vulnerabilities that can be exploited. Each vulnerability can happen at all levels of the application stack. Let’s proceed to identify potential vulnerabilities:</p>
<ul>
<li>An operating system has unpatched software with vulnerabilities.</li>
<li>An operating system is missing security settings (e.g., no firewall).</li>
<li>An operating system is lacking proper account management.</li>
<li>Using an operating system that is end-of-life.</li>
<li>Using a software runtime that is end-of-life.</li>
<li>Using a software runtime with known vulnerabilities.</li>
<li>Running the software runtime without account restrictions.</li>
<li>Using software libraries or packages with vulnerabilities.</li>
<li>Improperly configuring the database.</li>
<li>Giving the database full Internet connectivity.</li>
<li>And there is a lot more.</li>
</ul>
<p>As you can see, the application attack surface can be more significant, especially when security was not a priority when building the application.</p>
<h1 id="heading-how-serverless-can-reduce-the-attack-surface">How Serverless Can Reduce The Attack Surface</h1>
<p>Using a serverless environment can reduce the attack surface. We would only need to focus on the topmost application layer in the <a target="_blank" href="https://en.wikipedia.org/wiki/OSI_model">OSI model</a>. But, how can serverless reduce the attack surface? Let’s look at the previously identified vulnerabilities and see how serverless can reduce or eliminate them.</p>
<ul>
<li>An operating system has unpatched software with vulnerabilities. <em>The cloud provider is responsible for patching the infrastructure and does it periodically.</em></li>
<li>An operating system is missing security settings (e.g., no firewall). <em>The cloud provider is responsible for securely configuring the infrastructure with the proper security settings to protect itself.</em></li>
<li>An operating system is lacking proper account management. <em>The cloud provider is responsible for setting up the proper account management for the infrastructure.</em></li>
<li>Using an operating system that is end-of-life. <em>The cloud provider is responsible for ensuring it only uses currently supported operating systems.</em></li>
<li>Using a software runtime that is end-of-life. <em>The cloud provider is responsible for ensuring it only uses currently supported software runtimes.</em></li>
<li>Using a software runtime with known vulnerabilities. <em>The cloud provider is responsible for keeping the software runtime up-to-date.</em></li>
<li>Running the software runtime without account restrictions. <em>The cloud provider is responsible for securely configuring the software run time.</em></li>
<li>Using software libraries or packages with vulnerabilities. <em>The developer is responsible for auditing the software libraries and packages.</em></li>
<li>Improperly configuring the database. <em>The cloud provider is responsible for securely configuring the database.</em></li>
<li>Giving the database full Internet connectivity. <em>The cloud provider is responsible for securely configuring network connectivity.</em></li>
<li>And there is a lot more.</li>
</ul>
<p>As you may have noticed, we offloaded our security configuration, maintenance, and risks to the cloud provider for all but one vulnerability.</p>
<h1 id="heading-serverless-is-not-a-silver-bullet-or-a-golden-gun">Serverless is not a silver bullet or a golden gun.</h1>
<p>Serverless comes with its own risks. The Open Web Application Security Project (OWASP) publishes the <a target="_blank" href="https://owasp.org/www-project-serverless-top-10/">OWASP Serverless Top Ten</a> that identifies the topmost security risks in serverless applications. Like with any application, it can be more or less vulnerable depending on the architecture, design, implementation, use, and maintenance. This post highlights how serverless can potentially reduce your application’s attack surface, especially if you do not have security expertise, time, or resources to deploy a secure application.</p>
<h2 id="heading-before-you-go">Before you go</h2>
<div class="hn-embed-widget" id="mailing-list"></div><h3 id="heading-about-the-author">About the author</h3>
<div class="hn-embed-widget" id="bio"></div><hr />

<p><em>Originally published on <a target="_blank" href="https://www.secjuice.com/how-serverless-reduces-your-attack-surface/">Secjuice.com</a></em></p>
<p><em>Photo by <a target="_blank" href="https://unsplash.com/@spanic">Damir Spanic</a> on <a target="_blank" href="https://unsplash.com">Unsplash</a></em></p>
]]></content:encoded></item></channel></rss>