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

<channel>
	<title>Security Archives | SQL Solutions Group</title>
	<atom:link href="https://sqlsolutionsgroup.com/category/security/feed/" rel="self" type="application/rss+xml" />
	<link>https://sqlsolutionsgroup.com/category/security/</link>
	<description></description>
	<lastBuildDate>Mon, 30 Mar 2026 03:33:31 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.9.4</generator>

<image>
	<url>https://sqlsolutionsgroup.com/wp-content/uploads/2021/01/cropped-SSG_FAVICON0002-32x32.png</url>
	<title>Security Archives | SQL Solutions Group</title>
	<link>https://sqlsolutionsgroup.com/category/security/</link>
	<width>32</width>
	<height>32</height>
</image> 
	<item>
		<title>Still Running SQL Server 2016? Here’s Why It’s Time to Upgrade</title>
		<link>https://sqlsolutionsgroup.com/still-running-sql-server-2016-heres-why-its-time-to-upgrade/</link>
					<comments>https://sqlsolutionsgroup.com/still-running-sql-server-2016-heres-why-its-time-to-upgrade/#respond</comments>
		
		<dc:creator><![CDATA[A.K. Gonzalez]]></dc:creator>
		<pubDate>Fri, 03 Apr 2026 03:16:37 +0000</pubDate>
				<category><![CDATA[Performance]]></category>
		<category><![CDATA[Security]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[SQL Server 2025]]></category>
		<category><![CDATA[#microsftcertifedmaster]]></category>
		<category><![CDATA[#microsftpartner]]></category>
		<category><![CDATA[#sql2016]]></category>
		<category><![CDATA[#sql2025]]></category>
		<category><![CDATA[#SQLAB]]></category>
		<category><![CDATA[#SQlatinoamerica]]></category>
		<category><![CDATA[#sqldatabase]]></category>
		<category><![CDATA[#sqldeveloper]]></category>
		<category><![CDATA[#SQLgroupie]]></category>
		<category><![CDATA[#sqlimer]]></category>
		<category><![CDATA[#sqlinjection]]></category>
		<category><![CDATA[#sqlinternals]]></category>
		<category><![CDATA[#sqlite]]></category>
		<category><![CDATA[#SQLLearning]]></category>
		<category><![CDATA[#SQLMagazine]]></category>
		<category><![CDATA[#sqlmanagementstudio]]></category>
		<category><![CDATA[#sqlmanager]]></category>
		<category><![CDATA[#Sqlmap]]></category>
		<category><![CDATA[#sqlserver]]></category>
		<category><![CDATA[#sqlserver2022]]></category>
		<category><![CDATA[#SQLsolutionsgroup]]></category>
		<category><![CDATA[#SQLTraining]]></category>
		<category><![CDATA[#SQLYog]]></category>
		<category><![CDATA[SQLPASS]]></category>
		<category><![CDATA[SQLSaturday]]></category>
		<category><![CDATA[SSG]]></category>
		<guid isPermaLink="false">https://sqlsolutionsgroup.com/?p=7459</guid>

					<description><![CDATA[<p>Many organizations are still relying on SQL Server 2016 to power critical systems. It’s familiar, stable, and “still working”—so it’s easy to push an upgrade down the priority list. But here’s the reality: SQL Server 2016 has reached end of life. And that shouldn&#8217;t be ignored. What “End of Life” Actually Means When Microsoft ends [&#8230;]</p>
<p>The post <a href="https://sqlsolutionsgroup.com/still-running-sql-server-2016-heres-why-its-time-to-upgrade/">Still Running SQL Server 2016? Here’s Why It’s Time to Upgrade</a> appeared first on <a href="https://sqlsolutionsgroup.com">SQL Solutions Group</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p class="p1"><em><strong><span class="s1">Many organizations are still relying on <span class="s2">SQL Server 2016</span> to power critical systems. It’s familiar, stable, and “still working”—so it’s easy to push an upgrade down the priority list.</span></strong></em></p>
<p class="p1"><em><strong><span class="s1">But here’s the reality: SQL Server 2016 has reached end of life. And that shouldn&#8217;t be ignored.</span></strong></em></p>
<hr />
<h2><span class="s1">What “End of Life” Actually Means</span></h2>
<p class="p1"><span class="s1">When Microsoft ends support for a product, it’s not just a technical milestone—it’s a risk shift. The list of &#8216;cons&#8217; becomes much longer than the list of  &#8216;pros&#8217; when deciding if an upgrade is neccesary yet, or if you can put it off another year. </span></p>
<p class="p1"><span class="s1">Officially SQL Server 2016 will have:</span></p>
<ul>
<li>
<p class="p1"><span class="s1">No more security updates</span></p>
</li>
<li>
<p class="p1"><span class="s1">No bug fixes or patches</span></p>
</li>
<li>
<p class="p1"><span class="s1">No official Microsoft support</span></p>
</li>
<li>
<p class="p1"><span class="s1">Increased exposure to vulnerabilities and compliance risks</span></p>
</li>
</ul>
<p class="p1"><span class="s1">Even if your system seems stable today, it’s now operating without a safety net. And in today’s environment, that’s a serious concern.</span></p>
<h2><span class="s1">The Hidden Cost of Staying Put</span></h2>
<p class="p1"><span class="s1">Delaying an upgrade might feel like the easier (and cheaper) option—but it often comes with hidden costs such as security risks, compliance issues, performance limiations and the need for emergency migrations.</span></p>
<p class="p1"><span class="s1">Without ongoing patches, your database becomes more vulnerable to attacks, especially ransomware targeting outdated systems. </span><span class="s1">Many industries require supported software. Running end-of-life systems can put you out of compliance with security standars. </span><span class="s1">Older systems miss out on years of performance improvements, optimization features, and efficiency gains. </span><span class="s1">Waiting too long often leads to rushed, reactive upgrades after a failure or breach—which are far more expensive and disruptive.</span></p>
<h2><span class="s1">What You Gain by Upgrading</span></h2>
<p class="p1"><span class="s1">Moving to a modern platform like <span class="s2">S</span><span class="s2">QL Server 2025</span> isn’t just about staying supported, it’s about unlocking better performance, resilience, and flexibility. </span><span class="s1">Newer versions bring query optimization, smarter resource usage, and faster processing, improving overall performance. There&#8217;s also some exciting new ways to make backup recovery smarter like: </span></p>
<ul>
<li>
<p class="p1"><span class="s1">True full and differential backups on secondary replicas</span></p>
</li>
<li>
<p class="p1"><span class="s1">Improved compression with ZSTD</span></p>
</li>
<li>
<p class="p1"><span class="s1">Immutable backup storage options</span></p>
</li>
</ul>
<p><span class="s1">The new upgrade also means stronger security and cloud-ready flexibility. </span><span class="s1">Modern encryption, threat detection, and tighter integration with cloud security tools help protect your data. And e</span><span class="s1">asier integration with Azure and hybrid environments gives you more options for scaling and disaster  recoverry.</span></p>
<h2><span class="s1">Migration Doesn’t Have to Be Overwhelming</span></h2>
<p class="p1"><span class="s1">One of the biggest reasons businesses delay upgrading is fear of disruption. </span><span class="s1">Downtime, data loss, compatibility issues, etc.  </span><span class="s1">But with the right strategy migrations can be smoooth, controlled, and predictable.</span></p>
<p class="p1"><span class="s1">A well executed upgrade includes:</span></p>
<ul>
<li>
<p class="p1"><span class="s1">A full assessment of your current environment</span></p>
</li>
<li>
<p class="p1"><span class="s1">Compatibility and workload analysis</span></p>
</li>
<li>
<p class="p1"><span class="s1">A clear migration plan with rollback options</span></p>
</li>
<li>
<p class="p1"><span class="s1">Testing before going live</span></p>
</li>
<li>
<p class="p1"><span class="s1">Minimal downtime during cutover</span></p>
</li>
</ul>
<h2><span class="s1">How We Help</span></h2>
<p class="p1"><span class="s1">We specialize in helping businesses move from outdated systems to modern, optimized environments—without the chaos.</span></p>
<p class="p1"><span class="s1">Our approach focuses on:</span></p>
<p class="p1"><span class="s1">✔️ Safe, secure data migration</span></p>
<p class="p1"><span class="s1">✔️ Minimal disruption to your operations</span></p>
<p class="p1"><span class="s1">✔️ Performance tuning post-upgrade</span></p>
<p class="p1"><span class="s1">✔️ Modern backup and recovery setup</span></p>
<p class="p1"><span class="s1">✔️ Long-term scalability and support</span></p>
<p class="p1"><span class="s1">Whether you’re running a single database or a complex environment, we make the transition manageable and worth it.</span></p>
<h2><span class="s1">Ready to Modernize Your SQL Environment?</span></h2>
<p class="p1"><span class="s1">If you’re still on SQL Server 2016, now is the time to act. </span><span class="s1">Let’s build a plan to upgrade your system, migrate your data safely, and set you up with a faster, more secure, and more resilient environment.</span></p>
<p class="p1"><span class="s1">Reach out today to start your upgrade the right way.</span></p>
<p>The post <a href="https://sqlsolutionsgroup.com/still-running-sql-server-2016-heres-why-its-time-to-upgrade/">Still Running SQL Server 2016? Here’s Why It’s Time to Upgrade</a> appeared first on <a href="https://sqlsolutionsgroup.com">SQL Solutions Group</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sqlsolutionsgroup.com/still-running-sql-server-2016-heres-why-its-time-to-upgrade/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
		<item>
		<title>Security Configuration for Linked Servers</title>
		<link>https://sqlsolutionsgroup.com/linked-server-security/</link>
					<comments>https://sqlsolutionsgroup.com/linked-server-security/#comments</comments>
		
		<dc:creator><![CDATA[Randy Knight]]></dc:creator>
		<pubDate>Wed, 04 Mar 2020 15:41:00 +0000</pubDate>
				<category><![CDATA[Security]]></category>
		<category><![CDATA[SQL Group]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[#microsftcertifedmaster]]></category>
		<category><![CDATA[#microsftpartner]]></category>
		<category><![CDATA[#SQLAB]]></category>
		<category><![CDATA[#SQlatino]]></category>
		<category><![CDATA[#SQlatinoamerica]]></category>
		<category><![CDATA[#sqldatabase]]></category>
		<category><![CDATA[#sqldeveloper]]></category>
		<category><![CDATA[#SQLgroupie]]></category>
		<category><![CDATA[#sqlimer]]></category>
		<category><![CDATA[#sqlimerbymay]]></category>
		<category><![CDATA[#sqlinjection]]></category>
		<category><![CDATA[#sqlinternals]]></category>
		<category><![CDATA[#sqlite]]></category>
		<category><![CDATA[#sqlite3]]></category>
		<category><![CDATA[#SQLLearning]]></category>
		<category><![CDATA[#SQLMagazine]]></category>
		<category><![CDATA[#sqlmanagementstudio]]></category>
		<category><![CDATA[#sqlmanager]]></category>
		<category><![CDATA[#Sqlmap]]></category>
		<category><![CDATA[#sqlrun]]></category>
		<category><![CDATA[#sqlsaturday2017]]></category>
		<category><![CDATA[#sqlsatvienna]]></category>
		<category><![CDATA[#sqlserver]]></category>
		<category><![CDATA[#SQLserver2012]]></category>
		<category><![CDATA[#sqlserver2014]]></category>
		<category><![CDATA[#sqlserver2017]]></category>
		<category><![CDATA[#sqlserver2022]]></category>
		<category><![CDATA[#SQLServeronLinux]]></category>
		<category><![CDATA[#SQLsolutionsgroup]]></category>
		<category><![CDATA[#SQLTraining]]></category>
		<category><![CDATA[#SQLYog]]></category>
		<category><![CDATA[linked server]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQLPASS]]></category>
		<category><![CDATA[SQLSaturday]]></category>
		<category><![CDATA[SSG]]></category>
		<guid isPermaLink="false">http://sqlsolutionsgroup.com/?p=3040</guid>

					<description><![CDATA[<p>A few years ago I published an article about how to use linked servers to avoid performance issues. I wanted to follow up on that with a discussion of linked server security configuration because this is another big issue I see all too often with linked servers. The first thing to understand is that all [&#8230;]</p>
<p>The post <a href="https://sqlsolutionsgroup.com/linked-server-security/">Security Configuration for Linked Servers</a> appeared first on <a href="https://sqlsolutionsgroup.com">SQL Solutions Group</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>A few years ago I published an <a href="https://sqlsolutionsgroup.com/using-linked-servers-the-right-way/">article</a> about how to use linked servers to avoid performance issues. I wanted to follow up on that with a discussion of linked server security configuration because this is another big issue I see all too often with linked servers.</p>
<p>The first thing to understand is that all linked server objects are accessible by everyone in the public database role (normally everybody). So what you are doing when you configure the security for a linked server is determining what the security context of the login will be on the remote server. The permissions of that login on the remote server will ultimately determine what the user can and can’t do.</p>
<hr />
<p class="has-text-align-center" style="font-size: 20px;">A 750-point Health Check from SQL Solutions Group includes a security audit.</p>
<p class="has-text-align-center" style="font-size: 20px;">Find out how healthy your SQL Server estate really is.</p>
<p class="has-text-align-center" style="font-size: 20px;"><a href="https://sqlsolutionsgroup.com/services/sql-health-check/" target="_blank" rel="noopener noreferrer"><span style="text-decoration: underline;">Learn More</span></a></p>
<hr />
<p>What we will be looking at is the <strong>Security</strong> tab of the linked server dialog. We’ll also look at the system stored procedures being executed behind the scenes. You can see these yourself by clicking the <strong>Script</strong> button after configuring the security in the GUI.</p>
<p><a href="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/2016-09-29_15-47-26-1.png"><img fetchpriority="high" decoding="async" class="alignnone wp-image-3047" src="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/2016-09-29_15-47-26-1-300x271.png" alt="linked server security" width="576" height="521" srcset="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/2016-09-29_15-47-26-1-300x271.png 300w, https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/2016-09-29_15-47-26-1.png 750w" sizes="(max-width: 576px) 100vw, 576px" /></a></p>
<h3>Default Behavior for Unmapped Logins</h3>
<p>The top part of the dialog box allows us to map local logins to remote logins. This is fairly straightforward and not where the problem usually lies so we’re going to focus on what happens if there is not a mapped login.</p>
<p>We’ll look at the options one at a time.</p>
<h4>Not be made</h4>
<p><a href="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/image-1.png"><img decoding="async" class="alignnone wp-image-3047" src="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/image-1.png" alt="linked server security" width="575" height="493" /></a></p>
<p>In this case, all that is done is to create the linked server with no login behavior specified. Without any mapped logins, the linked server is useless.</p>
<pre class="lang:tsql decode:true "><div id="wpshdo_1" class="wp-synhighlighter-outer"><div id="wpshdt_1" class="wp-synhighlighter-expanded"><table border="0" width="100%"><tr><td align="left" width="80%"><a name="#codesyntax_1"></a><a id="wpshat_1" class="wp-synhighlighter-title" href="#codesyntax_1"  onClick="javascript:wpsh_toggleBlock(1)" title="Click to show/hide code block">Source code</a></td><td align="right"><a href="#codesyntax_1" onClick="javascript:wpsh_code(1)" title="Show code only"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/code.png" /></a>&nbsp;<a href="#codesyntax_1" onClick="javascript:wpsh_print(1)" title="Print code"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/printer.png" /></a>&nbsp;<a href="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/About.html" target="_blank" title="Show plugin information"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/info.gif" /></a>&nbsp;</td></tr></table></div><div id="wpshdi_1" class="wp-synhighlighter-inner" style="display: block;"><pre class="tsql" style="font-family:monospace;"><span class="kw1">EXEC</span> master.<span class="me1">dbo</span>.<span class="kw3">sp_addlinkedserver</span> @server <span class="sy0">=</span> N<span class="st0">'SERVER1'</span>, @srvproduct<span class="sy0">=</span>N<span class="st0">'SQL Server'</span></pre></div></div></pre>
<p>If we try to execute a linked server query, we get the following results:</p>
<pre class="lang:tsql decode:true "><div id="wpshdo_2" class="wp-synhighlighter-outer"><div id="wpshdt_2" class="wp-synhighlighter-expanded"><table border="0" width="100%"><tr><td align="left" width="80%"><a name="#codesyntax_2"></a><a id="wpshat_2" class="wp-synhighlighter-title" href="#codesyntax_2"  onClick="javascript:wpsh_toggleBlock(2)" title="Click to show/hide code block">Source code</a></td><td align="right"><a href="#codesyntax_2" onClick="javascript:wpsh_code(2)" title="Show code only"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/code.png" /></a>&nbsp;<a href="#codesyntax_2" onClick="javascript:wpsh_print(2)" title="Print code"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/printer.png" /></a>&nbsp;<a href="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/About.html" target="_blank" title="Show plugin information"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/info.gif" /></a>&nbsp;</td></tr></table></div><div id="wpshdi_2" class="wp-synhighlighter-inner" style="display: block;"><pre class="tsql" style="font-family:monospace;"><span class="kw1">select</span> name <span class="kw1">from</span> SERVER1.<span class="me1">master</span>.<span class="me1">sys</span>.<span class="me1">databases</span></pre></div></div></pre>
<pre class="lang:tsql decode:true ">Msg 18456, Level 14, State 1, Line 7
Login failed for user 'NT AUTHORITY\ANONYMOUS LOGON'.</pre>
<p>It tried to make an anonymous connection to the remote server which thankfully did not work.</p>
<h4></h4>
<h4>Be made without using a security context</h4>
<p><a href="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/image-2.png"><img decoding="async" class="wp-image-3209 alignone" src="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/image-2.png" alt="linked server security" width="551" height="478" /></a></p>
<p>In this case, it explicitly creates a mapped login of NULL with @useself = &#8216;False&#8217;. In other words we are explicitly telling it not to pass a security context to the remote server whereas in the first option it tried an anonymous connection.</p>
<pre class="lang:tsql decode:true "><div id="wpshdo_3" class="wp-synhighlighter-outer"><div id="wpshdt_3" class="wp-synhighlighter-expanded"><table border="0" width="100%"><tr><td align="left" width="80%"><a name="#codesyntax_3"></a><a id="wpshat_3" class="wp-synhighlighter-title" href="#codesyntax_3"  onClick="javascript:wpsh_toggleBlock(3)" title="Click to show/hide code block">Source code</a></td><td align="right"><a href="#codesyntax_3" onClick="javascript:wpsh_code(3)" title="Show code only"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/code.png" /></a>&nbsp;<a href="#codesyntax_3" onClick="javascript:wpsh_print(3)" title="Print code"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/printer.png" /></a>&nbsp;<a href="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/About.html" target="_blank" title="Show plugin information"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/info.gif" /></a>&nbsp;</td></tr></table></div><div id="wpshdi_3" class="wp-synhighlighter-inner" style="display: block;"><pre class="tsql" style="font-family:monospace;"><span class="kw1">EXEC</span> master.<span class="me1">dbo</span>.<span class="kw3">sp_addlinkedserver</span> @server <span class="sy0">=</span> N<span class="st0">'SERVER1'</span>, @srvproduct<span class="sy0">=</span>N<span class="st0">'SQL Server'</span>, @provider<span class="sy0">=</span>N<span class="st0">'SQLNCLI11'</span>, @datasrc<span class="sy0">=</span>N<span class="st0">'SERVER1'</span>
<span class="kw1">EXEC</span> master.<span class="me1">dbo</span>.<span class="kw3">sp_addlinkedsrvlogin</span> @rmtsrvname<span class="sy0">=</span>N<span class="st0">'SERVER1'</span>,@useself<span class="sy0">=</span>N<span class="st0">'False'</span>,@locallogin<span class="sy0">=NULL</span>,@rmtuser<span class="sy0">=NULL</span>,@rmtpassword<span class="sy0">=NULL</span></pre></div></div></pre>
<p>Let’s see what happens when we execute the query here.</p>
<pre class="lang:tsql decode:true "><div id="wpshdo_4" class="wp-synhighlighter-outer"><div id="wpshdt_4" class="wp-synhighlighter-expanded"><table border="0" width="100%"><tr><td align="left" width="80%"><a name="#codesyntax_4"></a><a id="wpshat_4" class="wp-synhighlighter-title" href="#codesyntax_4"  onClick="javascript:wpsh_toggleBlock(4)" title="Click to show/hide code block">Source code</a></td><td align="right"><a href="#codesyntax_4" onClick="javascript:wpsh_code(4)" title="Show code only"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/code.png" /></a>&nbsp;<a href="#codesyntax_4" onClick="javascript:wpsh_print(4)" title="Print code"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/printer.png" /></a>&nbsp;<a href="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/About.html" target="_blank" title="Show plugin information"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/info.gif" /></a>&nbsp;</td></tr></table></div><div id="wpshdi_4" class="wp-synhighlighter-inner" style="display: block;"><pre class="tsql" style="font-family:monospace;"><span class="kw1">select</span> name <span class="kw1">from</span> SERVER1.<span class="me1">master</span>.<span class="me1">sys</span>.<span class="me1">databases</span></pre></div></div></pre>
<pre class="lang:tsql decode:true ">OLE DB provider "SQLNCLI11" for linked server "SERVER1" returned message "Invalid authorization specification".
Msg 7399, Level 16, State 1, Line 7
The OLE DB provider "SQLNCLI11" for linked server "SERVER1" reported an error. Authentication failed.
Msg 7303, Level 16, State 1, Line 7
Cannot initialize the data source object of OLE DB provider "SQLNCLI11" for linked server "SERVER1".</pre>
<p>This option is more secure than the first one simply because it would not work even if the anonymous login worked on the remote server.</p>
<h4></h4>
<h4>Be made using the login’s current security context</h4>
<p><a href="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/image-3.png"><img loading="lazy" decoding="async" class="wp-image-3209 alignone" src="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/image_thumb-3.png" alt="linked server security" width="552" height="474" /></a></p>
<p>In this case, it is going to pass the security context of the local login to the remote login. If you have to have an option to connect without a mapped login, this is the best option. Note that the call to <strong>sp_addlinkedsrvlogin</strong> is almost the same as the last one. The only difference is that the <strong>@useself</strong> parameter is True.</p>
<pre class="lang:tsql decode:true "><div id="wpshdo_5" class="wp-synhighlighter-outer"><div id="wpshdt_5" class="wp-synhighlighter-expanded"><table border="0" width="100%"><tr><td align="left" width="80%"><a name="#codesyntax_5"></a><a id="wpshat_5" class="wp-synhighlighter-title" href="#codesyntax_5"  onClick="javascript:wpsh_toggleBlock(5)" title="Click to show/hide code block">Source code</a></td><td align="right"><a href="#codesyntax_5" onClick="javascript:wpsh_code(5)" title="Show code only"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/code.png" /></a>&nbsp;<a href="#codesyntax_5" onClick="javascript:wpsh_print(5)" title="Print code"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/printer.png" /></a>&nbsp;<a href="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/About.html" target="_blank" title="Show plugin information"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/info.gif" /></a>&nbsp;</td></tr></table></div><div id="wpshdi_5" class="wp-synhighlighter-inner" style="display: block;"><pre class="tsql" style="font-family:monospace;"><span class="kw1">EXEC</span> master.<span class="me1">dbo</span>.<span class="kw3">sp_addlinkedserver</span> @server <span class="sy0">=</span> N<span class="st0">'SERVER1'</span>, @srvproduct<span class="sy0">=</span>N<span class="st0">'SERVER1'</span>, @provider<span class="sy0">=</span>N<span class="st0">'SQLNCLI11'</span>, @datasrc<span class="sy0">=</span>N<span class="st0">'SERVER1'</span>
<span class="kw1">EXEC</span> master.<span class="me1">dbo</span>.<span class="kw3">sp_addlinkedsrvlogin</span> @rmtsrvname<span class="sy0">=</span>N<span class="st0">'SERVER1'</span>,@useself<span class="sy0">=</span>N<span class="st0">'True'</span>,@locallogin<span class="sy0">=NULL</span>,@rmtuser<span class="sy0">=NULL</span>,@rmtpassword<span class="sy0">=NULL</span></pre></div></div></pre>
<p>Let’s see what happens when we execute the query here.</p>
<pre class="lang:tsql decode:true "><div id="wpshdo_6" class="wp-synhighlighter-outer"><div id="wpshdt_6" class="wp-synhighlighter-expanded"><table border="0" width="100%"><tr><td align="left" width="80%"><a name="#codesyntax_6"></a><a id="wpshat_6" class="wp-synhighlighter-title" href="#codesyntax_6"  onClick="javascript:wpsh_toggleBlock(6)" title="Click to show/hide code block">Source code</a></td><td align="right"><a href="#codesyntax_6" onClick="javascript:wpsh_code(6)" title="Show code only"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/code.png" /></a>&nbsp;<a href="#codesyntax_6" onClick="javascript:wpsh_print(6)" title="Print code"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/printer.png" /></a>&nbsp;<a href="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/About.html" target="_blank" title="Show plugin information"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/info.gif" /></a>&nbsp;</td></tr></table></div><div id="wpshdi_6" class="wp-synhighlighter-inner" style="display: block;"><pre class="tsql" style="font-family:monospace;"><span class="kw1">select</span> name <span class="kw1">from</span> SERVER1.<span class="me1">master</span>.<span class="me1">sys</span>.<span class="me1">databases</span></pre></div></div></pre>
<p><a href="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/image-4.png"><img loading="lazy" decoding="async" class="wp-image-3209 alignone" src="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/image_thumb-4.png" alt="linked server security" width="303" height="301" /></a></p>
<p>It worked this time. The login used on the local server also existed on the remote server so the user connected as if they were directly connecting to the remote server. One thing to note is that with standard logins, this will only work if the login name AND password are the same on both instances. If the login name is the same and the password is different you will get the following error:</p>
<pre class="lang:tsql decode:true ">Msg 18456, Level 14, State 1, Line 11
Login failed for user 'UserA'.</pre>
<p>For this reason, this is a lot easier to deal with when using Active Directory accounts. As long as the AD-based login has permission on both instances it should work just fine, with one caveat. Depending on the configuration of the AD environment you’re in, you may run in what is known as the <a href="https://blogs.technet.microsoft.com/askds/2008/06/13/understanding-kerberos-double-hop/">Kerberos Double Hop issue</a>. Typically you’d be going from a user’s workstation to the local server to the remote server. So two hops. A full discussion of this is beyond the scope of this article but suffice it to say that Kerberos delegation must be properly configured in the environment for this to work.</p>
<h4>Be made using this security context</h4>
<p><a href="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/image-5.png"><img loading="lazy" decoding="async" class="wp-image-3209 alignone" src="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/image_thumb-5.png" alt="image" width="551" height="501" /></a></p>
<p>This is unfortunately both the most commonly used and the least secure way to address the security configuration of your linked server. What we are saying here is that every user who uses the linked server will be authenticated on the remote server using the credentials provided here. This is RARELY going to be the right thing to do in a secure environment. A user with public on the local server and nothing else will connect to the remote server using this login’s permissions which are usually higher than that. I’ve seen more than one environment using an account like <strong>linkedserver</strong> that exists and is a <strong>sysadmin</strong> on every server!</p>
<pre class="lang:tsql decode:true "><div id="wpshdo_7" class="wp-synhighlighter-outer"><div id="wpshdt_7" class="wp-synhighlighter-expanded"><table border="0" width="100%"><tr><td align="left" width="80%"><a name="#codesyntax_7"></a><a id="wpshat_7" class="wp-synhighlighter-title" href="#codesyntax_7"  onClick="javascript:wpsh_toggleBlock(7)" title="Click to show/hide code block">Source code</a></td><td align="right"><a href="#codesyntax_7" onClick="javascript:wpsh_code(7)" title="Show code only"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/code.png" /></a>&nbsp;<a href="#codesyntax_7" onClick="javascript:wpsh_print(7)" title="Print code"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/printer.png" /></a>&nbsp;<a href="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/About.html" target="_blank" title="Show plugin information"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/info.gif" /></a>&nbsp;</td></tr></table></div><div id="wpshdi_7" class="wp-synhighlighter-inner" style="display: block;"><pre class="tsql" style="font-family:monospace;"><span class="kw1">EXEC</span> master.<span class="me1">dbo</span>.<span class="kw3">sp_addlinkedserver</span> @server <span class="sy0">=</span> N<span class="st0">'SERVER1'</span>, @srvproduct<span class="sy0">=</span>N<span class="st0">'RKLAPTOPSS'</span>, @provider<span class="sy0">=</span>N<span class="st0">'SQLOLEDB'</span>, @datasrc<span class="sy0">=</span>N<span class="st0">'SERVER1'</span>
<span class="kw1">EXEC</span> master.<span class="me1">dbo</span>.<span class="kw3">sp_addlinkedsrvlogin</span> @rmtsrvname <span class="sy0">=</span> N<span class="st0">'SERVER1'</span>, @locallogin <span class="sy0">=</span> <span class="sy0">NULL</span> , @useself <span class="sy0">=</span> N<span class="st0">'False'</span>, @rmtuser <span class="sy0">=</span> N<span class="st0">'UserA'</span>, @rmtpassword <span class="sy0">=</span> N<span class="st0">'password'</span></pre></div></div></pre>
<p>I won’t bother executing the query for this one because obviously it will work.</p>
<h3>Remote Login Mapping</h3>
<p>We didn’t spend a lot of time on mapped logins because that is fairly straightforward. We can map a local login to a remote login, providing the login name and password on the remote server. This is useful if we can’t control the login name and password on the remote server. It is also useful if we want to control exactly who on the local server can use the remote server. If you have logins mapped here and are using one of the first two options for the default behavior, only these users will have access to the remote server via the linked server.</p>
<p>The Impersonate option is just what it sounds like. This is effectively the same as the <strong>Be made using the login’s current security context</strong> but applies to a specific login, not all of them.</p>
<p><a href="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/image-6.png"><img loading="lazy" decoding="async" class="wp-image-3209 alignone" src="https://sqlsolutionsgroup.com/wp-content/uploads/2016/09/image_thumb-6.png" alt="image" width="555" height="475" /></a></p>
<p>In this example, the only users who can access the remote server are <strong>UserA</strong> and <strong>UserB</strong>. For <strong>UserA</strong>, we have specified the login name and password on the remote server. <strong>UserB</strong> has the same login name and password on the remote server so impersonation can be used.</p>
<p>The post <a href="https://sqlsolutionsgroup.com/linked-server-security/">Security Configuration for Linked Servers</a> appeared first on <a href="https://sqlsolutionsgroup.com">SQL Solutions Group</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sqlsolutionsgroup.com/linked-server-security/feed/</wfw:commentRss>
			<slash:comments>4</slash:comments>
		
		
			</item>
		<item>
		<title>Easy Permissions Audit</title>
		<link>https://sqlsolutionsgroup.com/easy-permissions-audit/</link>
					<comments>https://sqlsolutionsgroup.com/easy-permissions-audit/#respond</comments>
		
		<dc:creator><![CDATA[Jason Brimhall]]></dc:creator>
		<pubDate>Mon, 13 Feb 2017 16:45:46 +0000</pubDate>
				<category><![CDATA[Security]]></category>
		<category><![CDATA[SQL Group]]></category>
		<category><![CDATA[SQL Server]]></category>
		<category><![CDATA[#microsftcertifedmaster]]></category>
		<category><![CDATA[#microsftpartner]]></category>
		<category><![CDATA[#SQLAB]]></category>
		<category><![CDATA[#SQlatino]]></category>
		<category><![CDATA[#SQlatinoamerica]]></category>
		<category><![CDATA[#sqldatabase]]></category>
		<category><![CDATA[#sqldeveloper]]></category>
		<category><![CDATA[#SQLgroupie]]></category>
		<category><![CDATA[#sqlimer]]></category>
		<category><![CDATA[#sqlimerbymay]]></category>
		<category><![CDATA[#sqlinjection]]></category>
		<category><![CDATA[#sqlinternals]]></category>
		<category><![CDATA[#sqlite]]></category>
		<category><![CDATA[#sqlite3]]></category>
		<category><![CDATA[#SQLLearning]]></category>
		<category><![CDATA[#SQLMagazine]]></category>
		<category><![CDATA[#sqlmanagementstudio]]></category>
		<category><![CDATA[#sqlmanager]]></category>
		<category><![CDATA[#Sqlmap]]></category>
		<category><![CDATA[#sqlrun]]></category>
		<category><![CDATA[#sqlsaturday2017]]></category>
		<category><![CDATA[#sqlsatvienna]]></category>
		<category><![CDATA[#sqlserver]]></category>
		<category><![CDATA[#SQLserver2012]]></category>
		<category><![CDATA[#sqlserver2014]]></category>
		<category><![CDATA[#sqlserver2017]]></category>
		<category><![CDATA[#sqlserver2022]]></category>
		<category><![CDATA[#SQLServeronLinux]]></category>
		<category><![CDATA[#SQLsolutionsgroup]]></category>
		<category><![CDATA[#SQLTraining]]></category>
		<category><![CDATA[#SQLYog]]></category>
		<category><![CDATA[Audit]]></category>
		<category><![CDATA[security]]></category>
		<category><![CDATA[SQL]]></category>
		<category><![CDATA[SQL Administration]]></category>
		<category><![CDATA[SQLPASS]]></category>
		<category><![CDATA[SQLSaturday]]></category>
		<category><![CDATA[SSG]]></category>
		<guid isPermaLink="false">http://sqlsolutionsgroup.com/?p=3086</guid>

					<description><![CDATA[<p>Something I have written about more than a handful of times is the need to audit. When people think about audits, the first thing that comes to mind is most likely the IRS and taxes. More than taxes are audit-able. Despite that tendency to first think taxes when somebody says &#8220;audit&#8221;, I am not writing about [&#8230;]</p>
<p>The post <a href="https://sqlsolutionsgroup.com/easy-permissions-audit/">Easy Permissions Audit</a> appeared first on <a href="https://sqlsolutionsgroup.com">SQL Solutions Group</a>.</p>
]]></description>
										<content:encoded><![CDATA[<p>Something I have written about more than a handful of times is the need to audit. When people think about audits, the first thing that comes to mind is most likely the IRS and taxes. More than taxes are audit-able. Despite that tendency to first think taxes when somebody says &#8220;audit&#8221;, I am not writing about taxes. I will typically write about the different topics within SQL Server that can be audited. Has Johnny performed a logon to the server? When was the last time the permissions to the database changed? Did somebody change an object? When was the last time stats were updated? How about auditing success and failure of your backups (or all agent jobs for that matter)? Those are the topics I will typically write about. Today, I am going to share a simple method to help perform an easy permissions audit permissions &#8211; on a manual basis.</p>
<h2>Easy Permissions Audit</h2>
<p>As the article title denotes, today I will be discussing a simple way to get quick permissions for various principals. If you are looking for a more comprehensive and human friendly report version, I recommend reading any of my many other articles on the topic such as the following article – <a href="https://bit.ly/anGB50">here</a> or <a href="https://bit.ly/pSqPJ9">here</a>. In the second of those links there is a clue as to what tool we will be using in this easy version of the audit. That tool is called sp_helprotect.</p>
<p>The stored procedure sp_helprotect is a system stored procedure from Microsoft that can help divulge permissions for various principals in a simple table result set for you. Bearing in mind that I am keeping this to a simple audit, the examples will be simplistic in nature. Without further ado, here is the easy audit for your permissions.</p>
<h3>sp_helprotect</h3>
<p>This stored procedure was introduced in SQL Server 2008 and comes with a few parameters to help narrow the results down to a specific principal and even to any object to which that principal may have been granted permissions. Here are those parameters for quick review:</p>
<p><strong>@name = </strong>This parameter is to filter your request down to a specific object or a statement that can be executed against that object (e.g. alter, create, drop)</p>
<p><strong>@username =</strong> Is the name of the principal for which permissions are returned.</p>
<p><strong>@grantorname =</strong> Is the name of the principal that granted permissions.</p>
<p><strong>@permissionarea =</strong> This is the group of grant-able permissions. There are two types of groups: object and statement. The default setting here is to return both groups.</p>
<p>The easiest way to use sp_helprotect is as follows:</p>
<div id="wpshdo_8" class="wp-synhighlighter-outer"><div id="wpshdt_8" class="wp-synhighlighter-expanded"><table border="0" width="100%"><tr><td align="left" width="80%"><a name="#codesyntax_8"></a><a id="wpshat_8" class="wp-synhighlighter-title" href="#codesyntax_8"  onClick="javascript:wpsh_toggleBlock(8)" title="Click to show/hide code block">Source code</a></td><td align="right"><a href="#codesyntax_8" onClick="javascript:wpsh_code(8)" title="Show code only"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/code.png" /></a>&nbsp;<a href="#codesyntax_8" onClick="javascript:wpsh_print(8)" title="Print code"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/printer.png" /></a>&nbsp;<a href="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/About.html" target="_blank" title="Show plugin information"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/info.gif" /></a>&nbsp;</td></tr></table></div><div id="wpshdi_8" class="wp-synhighlighter-inner" style="display: block;"><pre class="tsql" style="font-family:monospace;"><span class="kw1">USE</span> TestDB; <span class="co1">--my test database...you need to change it</span>
GO
&nbsp;
<span class="kw1">EXECUTE</span> sys.<span class="kw3">SP_HELPROTECT</span></pre></div></div>
<p>Do you see how easy that is? This returns the following results for me.</p>
<p><a class="thickbox" href="https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_simple.jpg"><img loading="lazy" decoding="async" class="aligncenter wp-image-5121 size-large" src="https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_simple-1024x339.jpg" sizes="(max-width: 560px) 100vw, 560px" srcset="https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_simple-1024x339.jpg 1024w, https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_simple-300x99.jpg 300w, https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_simple-768x254.jpg 768w, https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_simple-50x17.jpg 50w" alt="" width="560" height="185" /></a></p>
<p>Note from the results that I see results for roles and users for various different objects. This is due to how the procedure was executed – with no parameters. Using no parameters in this query, the default behavior is to return as much information as possible for all objects and principals within the database.</p>
<p>What if I only want the results for a principal named “Gargouille”? I can do that in the following way.</p>
<div id="wpshdo_9" class="wp-synhighlighter-outer"><div id="wpshdt_9" class="wp-synhighlighter-expanded"><table border="0" width="100%"><tr><td align="left" width="80%"><a name="#codesyntax_9"></a><a id="wpshat_9" class="wp-synhighlighter-title" href="#codesyntax_9"  onClick="javascript:wpsh_toggleBlock(9)" title="Click to show/hide code block">Source code</a></td><td align="right"><a href="#codesyntax_9" onClick="javascript:wpsh_code(9)" title="Show code only"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/code.png" /></a>&nbsp;<a href="#codesyntax_9" onClick="javascript:wpsh_print(9)" title="Print code"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/printer.png" /></a>&nbsp;<a href="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/About.html" target="_blank" title="Show plugin information"><img decoding="async" border="0" style="border: 0 none" src="https://sqlsolutionsgroup.com/wp-content/plugins/wp-synhighlight/themes/default/images/info.gif" /></a>&nbsp;</td></tr></table></div><div id="wpshdi_9" class="wp-synhighlighter-inner" style="display: block;"><pre class="tsql" style="font-family:monospace;"><span class="kw1">USE</span> TestDB; <span class="co1">--my test database...you need to change it</span>
GO
&nbsp;
<span class="kw1">EXECUTE</span> sys.<span class="kw3">SP_HELPROTECT</span> 
	@username <span class="sy0">=</span> <span class="st0">'gargouille'</span></pre></div></div>
<p>Now, I will receive the following results:</p>
<p><a class="thickbox" href="https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_gargouille.jpg"><img loading="lazy" decoding="async" class="aligncenter wp-image-5120 size-large" src="https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_gargouille-1024x142.jpg" sizes="(max-width: 560px) 100vw, 560px" srcset="https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_gargouille-1024x142.jpg 1024w, https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_gargouille-300x42.jpg 300w, https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_gargouille-768x107.jpg 768w, https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_gargouille-50x7.jpg 50w, https://jasonbrimhall.info/wp-content/uploads/2019/01/helprotect_gargouille.jpg 1298w" alt="" width="560" height="78" /></a></p>
<h2>Recap</h2>
<p>There are many ways to produce an audit. Today, I have shown how one can produce a permissions audit when in a hurry that will produce a simple result set for database permissions. I want to underscore that this was at the database level and not the server level. While this is an adequate means for a quick peek into some of the objects and granted permissions, I do recommend using one of the other methods I have introduced in the other articles for ongoing complex audits and results that are somewhat prettier and more human friendly to read.</p>
<p>The post <a href="https://sqlsolutionsgroup.com/easy-permissions-audit/">Easy Permissions Audit</a> appeared first on <a href="https://sqlsolutionsgroup.com">SQL Solutions Group</a>.</p>
]]></content:encoded>
					
					<wfw:commentRss>https://sqlsolutionsgroup.com/easy-permissions-audit/feed/</wfw:commentRss>
			<slash:comments>0</slash:comments>
		
		
			</item>
	</channel>
</rss>
