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

<channel>
	<title>Escalate &#8211; AnonyViet &#8211; English Version</title>
	<atom:link href="https://en.anonyviet.com/tag/escalate/feed/" rel="self" type="application/rss+xml" />
	<link>https://en.anonyviet.com</link>
	<description>The most popular website for sharing information technology, computer networks, and security knowledge. Stay up to date with the hottest news and tips</description>
	<lastBuildDate>Wed, 25 Jan 2023 01:49:32 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=7.0.2</generator>

<image>
	<url>https://en.anonyviet.com/wp-content/uploads/2023/01/cropped-ico-logo-75x75-1.png</url>
	<title>Escalate &#8211; AnonyViet &#8211; English Version</title>
	<link>https://en.anonyviet.com</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Use PowerRunAsAttached to Escalate Privileges on Windows</title>
		<link>https://en.anonyviet.com/use-powerrunasattached-to-escalate-privileges-on-windows/</link>
					<comments>https://en.anonyviet.com/use-powerrunasattached-to-escalate-privileges-on-windows/#respond</comments>
		
		<dc:creator><![CDATA[AnonyViet]]></dc:creator>
		<pubDate>Wed, 25 Jan 2023 01:49:32 +0000</pubDate>
				<category><![CDATA[Security]]></category>
		<category><![CDATA[Escalate]]></category>
		<category><![CDATA[PowerRunAsAttached]]></category>
		<category><![CDATA[Privileges]]></category>
		<category><![CDATA[Windows]]></category>
		<guid isPermaLink="false">https://en.anonyviet.com/?p=2435</guid>

					<description><![CDATA[Are you using a computer running Windows operating system but have a lot of Users but you want to access CMD and Powershell of other Users but you don&#8217;t want to get out of your current User? You don&#8217;t want to close your applications but you need access to another User to work? Don&#8217;t worry, [&#8230;]]]></description>
										<content:encoded><![CDATA[<p></p>
<div id="ftwp-postcontent">
<p><strong>Are you using a computer running Windows operating system but have a lot of Users but you want to access CMD and Powershell of other Users but you don&#8217;t want to get out of your current User?  You don&#8217;t want to close your applications but you need access to another User to work?  Don&#8217;t worry, today I will show you how to access the Console of other Users using a script called PowerRunAsAttached</strong></p>
<div class="code-block code-block-16" style="margin: 8px 0; clear: both;">
<div align="center">
<table class=" aligncenter" style="background-color: #c0c0c0; border-collapse: collapse; width: 59.9985%;">
<tbody>
<tr>
<td style="width: 100%; text-align: center;"><span style="font-size: 12pt;"><strong>Join the channel <span style="color: #0000ff;">Telegram</span> of the <span style="color: #008080;">AnonyViet </span> 👉 <span style="text-decoration: underline;"><a target="_blank" href="https://en.anonyviet.com/next-link?url=https%3A%2F%2Ft.me%2Fanonyvietchat" class="local-link" rel="noopener">Link</a></span>  👈</strong></span></td>
</tr>
</tbody>
</table>
</div>
</div>
<h2 id="ftoc-powerrunasattached-script-ho-tro-cho-cac-ban-lam-cong-nghe-thong-tin" class="ftwp-heading">PowerRunAsAttached – Script to support you in information technology</h2>
<p>Personally, on my computer there are many different Users to serve different jobs.  For example, I will normally have 3 Users including: 1 User for gaming, 1 User for coding and 1 User for others to use and they all have different purposes for more focus at work.  But sometimes I also have things I will need to use the rest of the User but I don&#8217;t want to get out of the current User?</p>
<p><img fetchpriority="high" decoding="async" class="size-full wp-image-38935 aligncenter" src="https://anonyviet.com/wp-content/uploads/2022/01/search.jpg" alt="PowerShell on windows" width="832" height="464" srcset="https://anonyviet.com/wp-content/uploads/2022/01/search.jpg 832w, https://anonyviet.com/wp-content/uploads/2022/01/search-300x167.jpg 300w, https://anonyviet.com/wp-content/uploads/2022/01/search-768x428.jpg 768w, https://anonyviet.com/wp-content/uploads/2022/01/search-750x418.jpg 750w" sizes="(max-width: 832px) 100vw, 832px" title="Use PowerRunAsAttached to Escalate Privileges on Windows 9"/></p>
<p>Pretty lucky for me when I found a script on the github community.  Your 1st PowerRunAsAttached Script has Username <a target="_blank" href="https://en.anonyviet.com/next-link/?url=https%3A%2F%2Fgithub.com%2FDarkCoderSc" rel="noopener external nofollow" class="ext-link" onclick="this.target='_blank';">DarkCoderSc</a> and this script is generated for the purpose of calling Console (CMD or Powershell) of other users.</p>
<p>Join me and set up now to be able to access the Console of other Users through PowerRunAsAttached!</p>
<h2 id="ftoc-huong-dan-su-dung-powerrunasattached-leo-thang-dac-quyen-tren-window" class="ftwp-heading">Instructions for using PowerRunAsAttached to escalate privileges on Windows</h2>
<h3 id="ftoc-phan-1-setup-script" class="ftwp-heading">Part 1: Setup Script</h3>
<p>To do this part, your device requires:</p>
<ul>
<li>Windows license has been activated</li>
<li>Fully updated</li>
<li>Have at least 2 Users or more</li>
</ul>
<p>After you have completed the above requirements, let&#8217;s go into how to Setup this script!</p>
<p><strong>Step 1</strong>: You download the script from github <a target="_blank" href="https://en.anonyviet.com/next-link/?url=https%3A%2F%2Fgithub.com%2FDarkCoderSc%2FPowerRunAsAttached" rel="noopener external nofollow" class="ext-link" onclick="this.target='_blank';">here</a>.  Then proceed to extract the file</p>
<p><strong>Step 2</strong>: In the PowerRunAsAttached-main folder, that folder will have a file named PowerRunAsAttached.  Do you remember the path to that file?</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-38936 aligncenter" src="https://anonyviet.com/wp-content/uploads/2022/01/a-8.jpg" alt="File PowerRunAsAttached" width="840" height="443" srcset="https://anonyviet.com/wp-content/uploads/2022/01/a-8.jpg 840w, https://anonyviet.com/wp-content/uploads/2022/01/a-8-300x158.jpg 300w, https://anonyviet.com/wp-content/uploads/2022/01/a-8-768x405.jpg 768w, https://anonyviet.com/wp-content/uploads/2022/01/a-8-750x396.jpg 750w" sizes="auto, (max-width: 840px) 100vw, 840px" title="Use PowerRunAsAttached to Escalate Privileges on Windows 10"/></p>
<p><strong>Step 3</strong>: Start Powershell as Administrator</p>
<p><strong>Step 4</strong>: In Powershell, write the following commands:</p>
<pre class="EnlighterJSRAW" data-enlighter-language="generic"># mẫu tham khảo&#13;
$p = [Environment]::GetEnvironmentVariable("PSModulePath")&#13;
$p += ";[đường dẫn tới file PowerRunAsAttached trong bước 2]"&#13;
[Environment]::SetEnvironmentVariable("PSModulePath",$p)</pre>
<pre class="EnlighterJSRAW" data-enlighter-language="generic"># Ví dụ&#13;
$p = [Environment]::GetEnvironmentVariable("PSModulePath")&#13;
$p += ";C:\Users\hoang\Desktop\PowerRunAsAttached-main\PowerRunAsAttached-main"&#13;
[Environment]::SetEnvironmentVariable("PSModulePath",$p)</pre>
<p><strong>Step 5</strong>: Please add the following command to import the script as a module</p>
<p><code>Import-Module PowerRunAsAttached</code></p>
<p><strong>Note</strong>: If it shows an error as shown below, then run the following command:</p>
<p><code>Set-ExecutionPolicy -ExecutionPolicy Unrestricted</code></p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-38937 aligncenter" src="https://anonyviet.com/wp-content/uploads/2022/01/a-9.jpg" alt="Security policy" width="803" height="142" srcset="https://anonyviet.com/wp-content/uploads/2022/01/a-9.jpg 803w, https://anonyviet.com/wp-content/uploads/2022/01/a-9-300x53.jpg 300w, https://anonyviet.com/wp-content/uploads/2022/01/a-9-768x136.jpg 768w, https://anonyviet.com/wp-content/uploads/2022/01/a-9-750x133.jpg 750w" sizes="auto, (max-width: 803px) 100vw, 803px" title="Use PowerRunAsAttached to Escalate Privileges on Windows 11"/></p>
<p>At this point, you have completed the setup.  Now I will show you how to use the script!</p>
<h3 id="ftoc-phan-2-huong-dan-su-dung-script" class="ftwp-heading">Part 2: Instructions for using scripts</h3>
<p>What you just need to enter on your Powershell is the command below:</p>
<p dir="auto"><code>Invoke-RunAsAttached -Username "[Tên username của user đó]" -Password "[password của user đó (để trống nếu không có)]"</code></p>
<p dir="auto">Eg:</p>
<p dir="auto"><code>Invoke-RunAsAttached -Username "wdchocopie" -Password "anonyviet123@"</code></p>
<p dir="auto"><img decoding="async" loading="lazy" class="size-full wp-image-38938 aligncenter" src="https://anonyviet.com/wp-content/uploads/2022/01/a-10.jpg" alt="Run the script " width="704" height="166" srcset="https://anonyviet.com/wp-content/uploads/2022/01/a-10.jpg 704w, https://anonyviet.com/wp-content/uploads/2022/01/a-10-300x71.jpg 300w" sizes="auto, (max-width: 704px) 100vw, 704px" title="Use PowerRunAsAttached to Escalate Privileges on Windows 12"/></p>
<p dir="auto">You can use the whoami command to check which user you are in!  Good luck</p>
<div class="kk-star-ratings kksr-auto kksr-align-right kksr-valign-bottom" data-payload="{&quot;align&quot;:&quot;right&quot;,&quot;id&quot;:&quot;38932&quot;,&quot;slug&quot;:&quot;default&quot;,&quot;valign&quot;:&quot;bottom&quot;,&quot;ignore&quot;:&quot;&quot;,&quot;reference&quot;:&quot;auto&quot;,&quot;class&quot;:&quot;&quot;,&quot;count&quot;:&quot;100&quot;,&quot;legendonly&quot;:&quot;&quot;,&quot;readonly&quot;:&quot;&quot;,&quot;score&quot;:&quot;5&quot;,&quot;starsonly&quot;:&quot;&quot;,&quot;best&quot;:&quot;5&quot;,&quot;gap&quot;:&quot;5&quot;,&quot;greet&quot;:&quot;\u0110\u00e1nh gi\u00e1 b\u00e0i vi\u1ebft post&quot;,&quot;legend&quot;:&quot;B\u00e0i vi\u1ebft \u0111\u1ea1t: 5\/5 - (100 b\u00ecnh ch\u1ecdn)&quot;,&quot;size&quot;:&quot;24&quot;,&quot;width&quot;:&quot;142.5&quot;,&quot;_legend&quot;:&quot;B\u00e0i vi\u1ebft \u0111\u1ea1t: {score}\/{best} - ({count} {votes})&quot;,&quot;font_factor&quot;:&quot;1.25&quot;}">
<p>            The article achieved: 5/5 &#8211; (100 votes)    </p>
</p></div>
</div>
]]></content:encoded>
					
					<wfw:commentRss>https://en.anonyviet.com/use-powerrunasattached-to-escalate-privileges-on-windows/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<media:content url="https://anonyviet.com/wp-content/uploads/2022/01/a-11.jpg" medium="image"></media:content>
            	</item>
		<item>
		<title>How to Escalate Linux Privileges Using SUID</title>
		<link>https://en.anonyviet.com/how-to-escalate-linux-privileges-using-suid/</link>
					<comments>https://en.anonyviet.com/how-to-escalate-linux-privileges-using-suid/#respond</comments>
		
		<dc:creator><![CDATA[AnonyViet]]></dc:creator>
		<pubDate>Tue, 24 Jan 2023 21:13:13 +0000</pubDate>
				<category><![CDATA[Network]]></category>
		<category><![CDATA[Escalate]]></category>
		<category><![CDATA[Linux]]></category>
		<category><![CDATA[Privileges]]></category>
		<category><![CDATA[SUID]]></category>
		<guid isPermaLink="false">https://en.anonyviet.com/?p=2205</guid>

					<description><![CDATA[This article will explain what privilege escalation is and how we can upgrade our privileges using the SUID permissions file. You can use this knowledge to solve Christmas Advent of Cyber ​​challenge number 8. Join the channel Telegram of the AnonyViet 👉 Link 👈 What is privilege escalation? Computer systems are designed to be used [&#8230;]]]></description>
										<content:encoded><![CDATA[<p></p>
<div id="ftwp-postcontent">
<p>This article will explain what privilege escalation is and how we can upgrade our privileges using the SUID permissions file.  You can use this knowledge to solve<a target="_blank" href="https://en.anonyviet.com/next-link/?url=https%3A%2F%2Ftryhackme.com%2Froom%2F25daysofchristmas" rel="noopener external nofollow" class="ext-link" onclick="this.target='_blank';"> Christmas Advent of Cyber ​​challenge number 8.</a></p>
<div class="code-block code-block-16" style="margin: 8px 0; clear: both;">
<div align="center">
<table class=" aligncenter" style="background-color: #c0c0c0; border-collapse: collapse; width: 59.9985%;">
<tbody>
<tr>
<td style="width: 100%; text-align: center;"><span style="font-size: 12pt;"><strong>Join the channel <span style="color: #0000ff;">Telegram</span> of the <span style="color: #008080;">AnonyViet </span> 👉 <span style="text-decoration: underline;"><a target="_blank" href="https://en.anonyviet.com/next-link?url=https%3A%2F%2Ft.me%2Fanonyvietchat" class="local-link" rel="noopener">Link</a></span>  👈</strong></span></td>
</tr>
</tbody>
</table>
</div>
</div>
<p><img post-id="2205" fifu-featured="1" decoding="async" class="aligncenter wp-image-33779 size-full" src="https://anonyviet.com/wp-content/uploads/2021/09/linux_security_thinkstock-100748604-large.jpg" alt="How to Escalate Linux Privileges Using SUID" title="How to Escalate Linux Privileges Using SUID" width="525" height="350" srcset="https://anonyviet.com/wp-content/uploads/2021/09/linux_security_thinkstock-100748604-large.jpg 525w, https://anonyviet.com/wp-content/uploads/2021/09/linux_security_thinkstock-100748604-large-300x200.jpg 300w" sizes="(max-width: 525px) 100vw, 525px" title="How to Escalate Linux Privileges Using SUID 8"/></p>
<h2 id="ftoc-leo-thang-dac-quyen-la-gi" class="ftwp-heading">What is privilege escalation?</h2>
<p>Computer systems are designed to be used by many users, and privileges mean what users are allowed to do.  Common privileges include viewing and editing files or modifying system files.</p>
<p>Privilege escalation is the act of exploiting a bug, design or configuration flaw in an operating system or software application to gain higher access to normally protected resources from an application or user. .</p>
<h2 id="ftoc-suid-la-gi" class="ftwp-heading">What is SUID?</h2>
<p>SUID is a special type of file permission granted to a file.  When a user runs a program, if they have the correct read/execute permissions, that program will run using their account privileges.  SUID allows a user to run a program using the privileges of another user.  To learn more about file perks, complete challenge 4 in the Christmas room or read the supporting material <a target="_blank" href="https://en.anonyviet.com/next-link/?url=https%3A%2F%2Fdocs.google.com%2Fdocument%2Fd%2F1CpwM_MdHgRqlPSe4eCC_-rVgi8F1xh88PKOySTRSkxU%2Fedit%3Fusp%3Dsharing" rel="noopener external nofollow" class="ext-link" onclick="this.target='_blank';">here</a>.</p>
<p>In some cases, we can take advantage of running the file as another user, to execute mining commands.  You might be thinking, why allow anyone to run the file as another user, right?  However, we need to have certain binaries run as root by an unprivileged user.</p>
<p>For example, if we change our password on Linux, the program that does this needs permission to change the file system.  You may not have write permission to the /etc/ directory, but root does.  This is why the password binary has the SUID bit.</p>
<p>If a binary file has a SUID bit then it will have permissions <strong>S.</strong> If we check the permissions for the password binary, we can see the permissions<strong> -rwsr-xr-x</strong>.</p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-33780 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/09/suid.png" alt="How to Escalate Linux Privileges Using SUID 4" width="466" height="38" srcset="https://anonyviet.com/wp-content/uploads/2021/09/suid.png 466w, https://anonyviet.com/wp-content/uploads/2021/09/suid-300x24.png 300w" sizes="auto, (max-width: 466px) 100vw, 466px" title="How to Escalate Linux Privileges Using SUID 9"/></p>
<p>The SUID bit is set on execute permission, which means that when a user runs this file, it will run as the file owner (as root).</p>
<p><strong>In essence, SUID files execute with the permission of the file owner.</strong></p>
<h2 id="ftoc-tan-dung-cac-file-suid" class="ftwp-heading">Make use of SUID files</h2>
<p>Some administrators will manually set the SUID bit to allow certain programs to be run.  Let&#8217;s say you are a system administrator and an unprivileged user wants to programmatically require the file to run with higher privileges.  They can set the SUID bit, then unprivileged users can execute the program without any additional account permissions.</p>
<p>We can scan the entire file system to find all files with the SUID bit, with the following command:</p>
<p><code>find / -user root -perm -4000 -exec ls -ldb {} \;</code></p>
<p><img decoding="async" loading="lazy" class="size-full wp-image-33785 aligncenter" src="https://anonyviet.com/wp-content/uploads/2021/09/suidfile.png" alt="How to Escalate Linux Privileges Using SUID 5" width="721" height="108" srcset="https://anonyviet.com/wp-content/uploads/2021/09/suidfile.png 721w, https://anonyviet.com/wp-content/uploads/2021/09/suidfile-300x45.png 300w" sizes="auto, (max-width: 721px) 100vw, 721px" title="How to Escalate Linux Privileges Using SUID 10"/></p>
<p>We can see some binaries running as root, which are legitimate programs with the right permissions set up to do the right task.</p>
<p>If a sysadmin has manually set the SUID bit on a binary file, the above command will find those files.  You can take advantage of this command to elevate your privileges or run commands you wouldn&#8217;t normally be able to do.</p>
<h2 id="ftoc-meo-danh-cho-thu-thach-suid" class="ftwp-heading">Tips for the SUID challenge</h2>
<p>A regular standard Linux binary (such as the find command), which can change the file owner and the SUID bit.</p>
<p>For example, if we want to know what user is running the find command, we can do the following:</p>
<pre><code>touch foo&#13;
find foo -exec whoami \;</code></pre>
<p>This command will find the file foo (which we just created), then run the command with the -exec parameter.</p>
<p>If you find a file that looks suspicious?  Try running it and see what you can do with it?  Run the whoami command to see if the file is actually running as root.</p>
<p>If you are given the option to run the command as another user.  Why not run /bin/bash to run bash (for the shell) as another user?</p>
<p>Also, you can check out Shodan.io readings on TryHackMe <a target="_blank" href="https://en.anonyviet.com/next-link?url=https%3A%2F%2Fanonyviet.com%2Fhuong-dan-giai-bai-ve-shodan-io-tren-tryhackme%2F" rel="noopener" class="local-link">here.</a></p>
<div class="kk-star-ratings kksr-auto kksr-align-right kksr-valign-bottom" data-payload="{&quot;align&quot;:&quot;right&quot;,&quot;id&quot;:&quot;33778&quot;,&quot;slug&quot;:&quot;default&quot;,&quot;valign&quot;:&quot;bottom&quot;,&quot;ignore&quot;:&quot;&quot;,&quot;reference&quot;:&quot;auto&quot;,&quot;class&quot;:&quot;&quot;,&quot;count&quot;:&quot;100&quot;,&quot;legendonly&quot;:&quot;&quot;,&quot;readonly&quot;:&quot;&quot;,&quot;score&quot;:&quot;5&quot;,&quot;starsonly&quot;:&quot;&quot;,&quot;best&quot;:&quot;5&quot;,&quot;gap&quot;:&quot;5&quot;,&quot;greet&quot;:&quot;\u0110\u00e1nh gi\u00e1 b\u00e0i vi\u1ebft post&quot;,&quot;legend&quot;:&quot;B\u00e0i vi\u1ebft \u0111\u1ea1t: 5\/5 - (100 b\u00ecnh ch\u1ecdn)&quot;,&quot;size&quot;:&quot;24&quot;,&quot;width&quot;:&quot;142.5&quot;,&quot;_legend&quot;:&quot;B\u00e0i vi\u1ebft \u0111\u1ea1t: {score}\/{best} - ({count} {votes})&quot;,&quot;font_factor&quot;:&quot;1.25&quot;}">
<p>            The article achieved: 5/5 &#8211; (100 votes)    </p>
</p></div>
</div>
]]></content:encoded>
					
					<wfw:commentRss>https://en.anonyviet.com/how-to-escalate-linux-privileges-using-suid/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
		<media:content url="https://anonyviet.com/wp-content/uploads/2021/09/linux_security_thinkstock-100748604-large.jpg" medium="image"></media:content>
            	</item>
	</channel>
</rss>
