<?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" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Samir Jasarat on Medium]]></title>
        <description><![CDATA[Stories by Samir Jasarat on Medium]]></description>
        <link>https://medium.com/@samirjasarat?source=rss-ccc094cc9835------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/2*f3XpJzeHMgGcDDSk-byJZg.jpeg</url>
            <title>Stories by Samir Jasarat on Medium</title>
            <link>https://medium.com/@samirjasarat?source=rss-ccc094cc9835------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Tue, 17 Nov 2026 01:18:14 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@samirjasarat/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[Utilizing AWS services to create, set up, and configure an EC2 instance to host a Java application…]]></title>
            <link>https://medium.com/@samirjasarat/utilizing-aws-services-to-create-set-up-and-configure-an-ec2-instance-to-host-a-java-application-dfae7a2dc430?source=rss-ccc094cc9835------2</link>
            <guid isPermaLink="false">https://medium.com/p/dfae7a2dc430</guid>
            <category><![CDATA[aws]]></category>
            <category><![CDATA[java]]></category>
            <category><![CDATA[jenkins-pipeline]]></category>
            <category><![CDATA[ec2-instance]]></category>
            <category><![CDATA[devops]]></category>
            <dc:creator><![CDATA[Samir Jasarat]]></dc:creator>
            <pubDate>Sat, 14 May 2022 18:16:47 GMT</pubDate>
            <atom:updated>2022-05-14T18:20:03.960Z</atom:updated>
            <content:encoded><![CDATA[<h3>Utilizing AWS services to create, set up, and configure an EC2 instance to host a Java application (Cloud/DevOps processes)</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*P8mLYK21VSA95UPOQVym9A.png" /></figure><p><strong>Creating the EC2</strong></p><p>1. So now we will need our EC2 to host our application and necessary tools.</p><p>2. In AWS, navigate to the EC2 portal and choose to launch a new one. Make sure you are comfortable with the Region you are creating it under.</p><p>3. You will want to check the “Free tier…” checkbox on the left-hand side. For our purposes, we will use the Amazon Linux AMI. (Amazon Machine Image) Don’t choose #2 as it is unnecessary for our purposes.</p><p>⦁ NOTE: CHECK THE “FREE TIER” OPTION.</p><p>4. Next you will pick your EBS (Elastic Block Store). Free tier allows only the t2.micro, so you can simply pick it and move on to the next step.</p><p>5. Now you should be at Step 3, the defaults are all that will be necessary here unless you want to spend money. Simply click the “Next: Add Storage” button on the bottom right.</p><p>6. Here you can allocate how much storage you want. (STEP 4 btw) You can use 30 GiB max for free. like to use 20 typically (probably because I’m paranoid about spending money when using AWS). Once you have your storage, move on to tags.</p><p>7. Next you will add tags for your EC2; these are for informational purposes only and you should add many in order to disambiguate your EC2s from each other. It is also useful in team environments for determining who is in charge of what and what each is being used for. Once done move on to the next step.</p><p>8. Now you are at security groups, this step is VERY IMPORTANT.</p><p>9. Here you determine what ports to allow access through and from where. NEVER OPEN ALL PORTS FOR ALL TRAFFIC, THESE KINDS OF SECURITIES ARE HACKED OFTEN.</p><p>10. For our purposes, I will keep port 22 for SSH and allow for “Anywhere”.</p><p>11. Next I will add a port for Jenkins on 8080.</p><p>12. Finally I add a port for Tomcat on 8088.</p><p>13. The ports are up to you, though you’ll probably choose these exact ports because you’ll be afraid not to follow this document to a tee.</p><p>14. In the step ahead you can review everything. Once done, choose to “Launch”.</p><p>15. You will be brought to the final step: the security key pair. Choose to either leverage an existing pair or create a new one. In either event, you will be prompted to download the key.</p><p>⦁ <em>DO NOT LOSE THIS KEY AS YOU WILL NOT BE ABLE TO LOG INTO YOUR EC2 WITHOUT IT. YOU WILL NOT BE GIVEN ANOTHER CHANCE TO DOWNLOAD IT EVER AGAIN. READ: YOU’LL HAVE TO SPIN UP A NEW EC2 INSTANCE IF YOU LOSE THIS KEY.</em></p><p>16. Once done, navigate to your EC2 portal on AWS and find the EC2 you created. Click it and you should see a details section below it. Here you can view all details and make changes as you may need to. For now we only care about the IPv4 Public IP as seen below:</p><p>With that we can move on to SSH into our EC2 to setup the environment.</p><p><strong>SSH Into Your EC2</strong></p><p>1. In order to connect to your EC2 you will need the key file you downloaded. There are a few steps that need to be performed to ensure it works:</p><p>⦁ FOR WINDOWS:</p><p>⦁ Ensure you aren’t using your key in an administrator environment. (Directly in the C:/ drive for instance.) If you need to do so, you will have to revoke permissions on the file for everyone but the user of the file. Also, limit it down to read only.</p><p>⦁ FOR MAC:</p><p>⦁ Invoke the following command on the file: sudo chmod 400 your-key-name.pem</p><p>⦁ This will allow you to use the key, should it prevent you otherwise.</p><p>2. To connect to the EC2, open up your shell/cmd with git commands installed to path, then invoke the following command to connect:</p><p>3. ssh -i location/of/your-key.pem ⦁ ec2-user@your.public.ip.address</p><p>⦁ The public ip address is on your EC2 information in AWS</p><p>⦁ “ec2-user” MUST be used.</p><p>5. Upon success you will be asked if you want to trust the connection. Enter “yes” (or “no” for some weird reason) and you should be greeted with the following:</p><p>6. To start things off you should invoke the following command in order to update your AMI</p><p>⦁ sudo yum -y update</p><p>⦁ “sudo” allows you to run a command with elevated permissions (as the super user)</p><p>⦁ “yum” is the package manager this distribution of Linux uses</p><p>⦁ the “-y” indicates that you want to say “yes” to all of the options you’ll be prompted to either accept or reject. Trust me: I’m saving you time.</p><p><strong>EC2 Environment: Java</strong></p><p>1. Your EC2 will have Java installed, but it will be an old version we don’t care to use. First remove this old version via:</p><p>⦁ sudo yum remove -y java</p><p>2. Next you will want to install a more up-to-date, open source Java JDK using the following command:</p><p>⦁ sudo yum install -y java-1.8.0-openjdk-devel</p><p>3. That should be all there is to this step.</p><p>⦁ You can confirm success by seeing Java 8 as the version with:</p><p>⦁ java -version</p><p>4. And confirming JAVA_HOME is properly set by invoking the following:</p><p>⦁ echo $JAVA_HOME</p><p>⦁ Which should yield: /usr/lib/jvm/jre</p><p>⦁ If for some reason you don’t have a JAVA_HOME, you must manually set your JAVA_HOME by navigating to the /etc/profile.d directory and adding a file which exports the JAVA_HOME variable.</p><p>NOTE: YOU’LL HAVE TO EXIT YOUR EC2 AND SSH BACK IN WHENEVER YOU ADD A NEW ENVIRONMENT VARIABLE.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=dfae7a2dc430" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[SeriousSAM Windows 10 vulnerability, outdated hashing technologies, and why some simple security…]]></title>
            <link>https://medium.com/@samirjasarat/serioussam-windows-10-vulnerability-outdated-hashing-technologies-and-why-simple-some-some-simple-16325c09d524?source=rss-ccc094cc9835------2</link>
            <guid isPermaLink="false">https://medium.com/p/16325c09d524</guid>
            <category><![CDATA[windows-10]]></category>
            <category><![CDATA[cyberattack]]></category>
            <category><![CDATA[cracking-hashes]]></category>
            <category><![CDATA[blue-team]]></category>
            <category><![CDATA[cybersecurity]]></category>
            <dc:creator><![CDATA[Samir Jasarat]]></dc:creator>
            <pubDate>Sat, 12 Feb 2022 18:41:25 GMT</pubDate>
            <atom:updated>2022-02-12T21:32:22.627Z</atom:updated>
            <content:encoded><![CDATA[<h3>SeriousSAM Windows 10 vulnerability, outdated hashing technologies, and why some simple security hygiene has EXPONENTIAL advantages.</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/728/1*fd2tJAgqCQB6Rdr0et-VSQ.jpeg" /></figure><p>File permissions are a tricky concept because they aren’t exactly part of the file themselves. So when files are copied, such as in the execution of a Microsoft function in Windows 10 that can take snapshots, or “shadow copies” of files and folders for copying and restoring files quickly, the permission structure for a series of portions in the OS does not remain correct. Permission management and assignment can become skewed, leading to a recently identified vulnerability: <strong>SeriousSAM</strong></p><p><strong>Security Account Manager (SAM) and vulnerable hashing technologies</strong></p><p>The SAM (Security Account Manager) is the part of the OS that contains hashed passwords and security tokens. When a regular user gains the permissions to read this file, they’ve now got access to hashed credentials for higher privilege accounts they should not be able to access or misuse, but certainly can. Malicious actors can use access to a file like this to execute a “Pass the Hash Attack”, or even reverse password hashes and execute a “Kerberos Silver Ticket Attack”. Microsoft has put out some advisories on defending against this weakness, but quite frankly currently Windows hashes are kept in the archaic LM hash or ineffective NTLM hash (v1 is not a hash and v2 is a weak hash). They use MD5 and DES encryption but it still may not be enough to safeguard against due to the recent advancements of computing capabilities. When Microsoft makes a change it impacts a huge portion of the industry, and changes to address weaknesses and vulnerabilities cannot just quickly be made by organizations.</p><p>NTLMv2 came out in 1998 but some systems still have to rely on the weaker LM hash for compatibility today. This means that even if SeriousSAM vulnerabilities are addressed today and password hashes are updated, it is probable the NTLMv2 hash will still be in use 20 or 30 years from now. This does present an interesting and alarming dilemma for companies like Microsoft and their enormous client bases today, and a problem in cybersecurity that many professionals and thought leaders are focused on addressing and proposing solutions for.</p><p><strong>Advice for teams and organizations</strong></p><p>This means that moving forward, it would be highly advisable for teams building new systems and applications to use modern hashes for credential storage, and also be very aware of files and their permissions when they are copied especially. These are two steps for good security heiygene that result in being able to avert and mitigate some serious modern day vulnerabilities and threats.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=16325c09d524" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[SIEM: Splunk Fundamentals]]></title>
            <link>https://medium.com/@samirjasarat/siem-splunk-fundamentals-5fb9899ba43d?source=rss-ccc094cc9835------2</link>
            <guid isPermaLink="false">https://medium.com/p/5fb9899ba43d</guid>
            <category><![CDATA[cybersecurity]]></category>
            <category><![CDATA[splunk]]></category>
            <category><![CDATA[incident-response]]></category>
            <dc:creator><![CDATA[Samir Jasarat]]></dc:creator>
            <pubDate>Sat, 05 Feb 2022 01:57:32 GMT</pubDate>
            <atom:updated>2022-02-05T01:57:32.201Z</atom:updated>
            <content:encoded><![CDATA[<p>A <strong>SIEM</strong> (<strong>Security Information and Event Management</strong>) is a software solution that provides a central location to collect log data from multiple sources within an environment. This data is aggregated and normalized, which can then be queried by an analyst.</p><p>This explores my personal journey and first experience with using a SIEM, and Splunk Enterprise in particular. After installing a Splunk instance on a Ubuntu 20.04 server VM in Virtual Box, navigating to the Splunk desktop interface URL (http://&lt;host-ip&gt;:8000/) in a browser leads us to the Splunk Enterprise home screen. Here is the <strong>Explore Splunk </strong>panel.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1018/0*x0ywbFVDtf7E0bVf.png" /></figure><p>In order to add data, I clicked on the <strong>New Index</strong> button in the upper right-hand corner. After creating four new indexes and ensuring that I have the data files needed to populate those indexes and uploading the respective files, the search and reporting app will be utilized to query and search through the data.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/367/0*qcvE05GQLwReK1sf.png" /></figure><p>After typing in * in the Search Bar and pressing the search magnifying glass, I am able to set the time picker for the data I want to query to a time window of the <strong>last 24 hours</strong>. My search results give me the following response:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*_EoS-GdGI11s8pS35OCX3A.png" /></figure><p>I then take the queried data, and further parse it by selecting any of the interesting fields on the left hand side to make my search even more specific to the data I need. I am able to create a SOC (Security of Operations) dashboard and modify my search results to do the following:</p><ol><li>Display a count of the top <strong>ClientIP </strong>addresses.</li><li>Add a visualization in Splunk for top usernames.</li><li>Add a visualization for any ClientIP containing pass in the password.</li></ol><figure><img alt="" src="https://cdn-images-1.medium.com/max/863/1*QX3IApt7-BcPvVl7ifP4QQ.png" /></figure><p>By utilizing the Extract Fields feature of the search and reporting app, I was able to extract the source ip and destination ip addresses of the data. I created a new report that shows attackers to victim IPs, and limited this queried data to the top 10 attacks from the attackers using a search for:<em> index=maccdc sourcetype=”etsnort” | top 10 srcip dstport.</em></p><p>Next, a Sankey Diagram visualization was installed as an add-on to Splunk to create the following report:</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/965/1*nbMYzs9nWI27s9vSKhKpMw.png" /></figure><p>The analysis of this report allows a SOC Analyst for instance to query the data and see that a large number of attacks are coming from one specific IP address, 192.168.202.110. This allows us to flag this IP address as a potential threat especially since it is targeting port 80 (HTTP) and port 8080, which is a common alternative for HTTP wherein SQL injections and Cross-site scripting attacks commonly target both ports.</p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=5fb9899ba43d" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>