<?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>PhoeNIXBird Networks</title>
	<atom:link href="https://www.pbnet.ro/?feed=rss2" rel="self" type="application/rss+xml" />
	<link>https://www.pbnet.ro</link>
	<description>Reality is changing</description>
	<lastBuildDate>Fri, 08 May 2026 14:06:03 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	
<site xmlns="com-wordpress:feed-additions:1">2475499</site>	<item>
		<title>[SPO] Sites and their IDs</title>
		<link>https://www.pbnet.ro/?p=375980</link>
		
		<dc:creator><![CDATA[Andrei Rachita]]></dc:creator>
		<pubDate>Fri, 08 May 2026 14:05:50 +0000</pubDate>
				<category><![CDATA[Microsoft Technologies]]></category>
		<guid isPermaLink="false">https://www.pbnet.ro/?p=375980</guid>

					<description><![CDATA[OK, since I get pretty often asked: how to I get a site&#8217;s ID or now, I have a site ID, how to I get <a class="mh-excerpt-more" href="https://www.pbnet.ro/?p=375980" title="[SPO] Sites and their IDs">[...]</a>]]></description>
										<content:encoded><![CDATA[<p>OK, since I get pretty often asked: how to I get a site&#8217;s ID or now, I have a site ID, how to I get the URL of the site?</p>
<p>Well, here&#8217;s how to do it:</p>
<p><em>Get SiteID: https://tenant.sharepoint.com/teams/site/_api/site/id</em></p>
<p>The response is something like: <span class="html-tag">&lt;d:Id<span class="html-attribute"> <span class="html-attribute-name">xmlns:d</span>=&#8221;<span class="html-attribute-value">http://schemas.microsoft.com/ado/2007/08/dataservices</span>&#8220;</span><span class="html-attribute"> <span class="html-attribute-name">xmlns:m</span>=&#8221;<span class="html-attribute-value">http://schemas.microsoft.com/ado/2007/08/dataservices/metadata</span>&#8220;</span><span class="html-attribute"> <span class="html-attribute-name">xmlns:georss</span>=&#8221;<span class="html-attribute-value">http://www.georss.org/georss</span>&#8220;</span><span class="html-attribute"> <span class="html-attribute-name">xmlns:gml</span>=&#8221;<span class="html-attribute-value">http://www.opengis.net/gml</span>&#8220;</span><span class="html-attribute"> <span class="html-attribute-name">m:type</span>=&#8221;<span class="html-attribute-value">Edm.Guid</span>&#8220;</span>&gt;</span>aa6733a3-1d04-4db4-b35c-9ee5674c3004<span class="html-tag">&lt;/d:Id&gt;</span></p>
<p><em>Get siteURL from ID: https://tenant.sharepoint.com/_api/SP.Site.GetUrlById(guid&#8217;aa6733a3-1d04-4db4-b35c-9ee5674c3004&#8242;)</em></p>
<p>The response will be like:</p>
<p><span class="html-tag">&lt;d:GetUrlById<span class="html-attribute"> <span class="html-attribute-name">xmlns:d</span>=&#8221;<span class="html-attribute-value">http://schemas.microsoft.com/ado/2007/08/dataservices</span>&#8220;</span><span class="html-attribute"> <span class="html-attribute-name">xmlns:m</span>=&#8221;<span class="html-attribute-value">http://schemas.microsoft.com/ado/2007/08/dataservices/metadata</span>&#8220;</span><span class="html-attribute"> <span class="html-attribute-name">xmlns:georss</span>=&#8221;<span class="html-attribute-value">http://www.georss.org/georss</span>&#8220;</span><span class="html-attribute"> <span class="html-attribute-name">xmlns:gml</span>=&#8221;<span class="html-attribute-value">http://www.opengis.net/gml</span>&#8220;</span>&gt;</span>https://tenant.sharepoint.com/teams/site<span class="html-tag">&lt;/d:GetUrlById&gt;</span></p>
<p>&nbsp;</p>
<p>Enjoy!</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">375980</post-id>	</item>
		<item>
		<title>[ASTERISK] How to have a talking clock</title>
		<link>https://www.pbnet.ro/?p=375922</link>
		
		<dc:creator><![CDATA[Andrei Rachita]]></dc:creator>
		<pubDate>Tue, 05 May 2026 14:24:30 +0000</pubDate>
				<category><![CDATA[Internet Voice]]></category>
		<guid isPermaLink="false">https://www.pbnet.ro/?p=375922</guid>

					<description><![CDATA[It all started when I remembered the service offered by the Romanian landline/PSTN provider Romtelecom back in the 80s and 90s. You used to call <a class="mh-excerpt-more" href="https://www.pbnet.ro/?p=375922" title="[ASTERISK] How to have a talking clock">[...]</a>]]></description>
										<content:encoded><![CDATA[<p>It all started when I remembered the service offered by the Romanian landline/PSTN provider Romtelecom back in the 80s and 90s.</p>
<p>You used to call the number 058, later 958 and get a lady saying: &#8220;At the next signal, the time will be exactly &lt;time&gt;&#8221;</p>
<p>OK, so I though, how can I implement this in my VoIP setup.</p>
<p>So, here goes:</p>
<p><em>Requirements:</em></p>
<ul>
<li>An already existing PBX where we will create the extension 958 that we can call</li>
<li>A Linux machine running Asterisk</li>
</ul>
<p>Here are the configs, supposing that you already have the Linux machine up and running. In this setup I used Ubuntu 26.04 on ARM:</p>
<p><strong>Install Asterisk</strong></p>
<p><em>sudo apt update</em><br />
<em>sudo apt install -y asterisk asterisk-modules asterisk-config</em></p>
<p><strong>Enable and start Asterisk</strong></p>
<p><em><span class="ͼl">sudo</span> systemctl enable <span class="ͼn">&#8211;now</span> asterisk</em><br />
<em><span class="ͼl">sudo</span> systemctl status asterisk</em></p>
<p>and verify Asterisk CLI is running: sudo asterisk -rvvvvv</p>
<p><em>Connected to Asterisk 22.5.2~dfsg+~cs6.15.60671435-1 currently running on asterisk-time (pid = 3022)</em></p>
<p><strong>Connect to your PBX extension</strong></p>
<p><em>sudo nano /etc/asterisk/pjsip.conf </em></p><pre class="crayon-plain-tag">[transport-udp]
type=transport
protocol=udp
bind=0.0.0.0:5060

[yeastar-auth]
type=auth
auth_type=userpass
username=958
password=YOUR_EXTENSION_958_PASSWORD

[yeastar-aor]
type=aor
contact=sip:PBXIP:5060

[yeastar-endpoint]
type=endpoint
transport=transport-udp
context=from-yeastar
disallow=all
allow=alaw
allow=ulaw
aors=yeastar-aor
outbound_auth=yeastar-auth
from_user=958
from_domain=PBXIP
direct_media=no
rtp_symmetric=yes
force_rport=yes
rewrite_contact=yes

[yeastar-identify]
type=identify
endpoint=yeastar-endpoint
match=PBXIP

[yeastar-reg]
type=registration
transport=transport-udp
outbound_auth=yeastar-auth
server_uri=sip:PBXIP:5060
client_uri=sip:958@PBXIP
contact_user=958
retry_interval=30
expiration=300
forbidden_retry_interval=30
auth_rejection_permanent=no</pre><p><strong>RELOAD ASTERISK</strong></p>
<p><em>sudo asterisk -rx &#8220;pjsip reload&#8221;</em><br />
<em>sudo asterisk -rx &#8220;pjsip send register yeastar-reg&#8221;</em><br />
<em>sudo asterisk -rx &#8220;pjsip show registrations&#8221;</em></p>
<p>The registration should look like:</p>
<p>&lt;Registration/ServerURI&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;&gt; &lt;Auth&#8230;&#8230;&#8230;&#8230;&#8230;&#8230;..&gt; &lt;Status&#8230;&#8230;.&gt;<br />
==========================================================================================</p>
<p>yeastar-reg/sip:PBXIP:5060 yeastar-auth Registered (exp. 558s)</p>
<p>Objects found: 1</p>
<p>&nbsp;</p>
<p><strong>EDIT THE EXTENSIONS (basically the &#8220;person&#8221; who will speak the time&#8221;)</strong></p>
<p><em>sudo nano /etc/asterisk/extensions.conf</em></p>
<p>&nbsp;</p>
<p>[from-yeastar]<br />
exten =&gt; 958,1,Answer()<br />
same =&gt; n,Wait(1)<br />
same =&gt; n(loop),Playback(at-tone-time-exactly)<br />
same =&gt; n,Wait(1)<br />
same =&gt; n,PlayTones(1000/250)<br />
same =&gt; n,Wait(1)<br />
same =&gt; n,StopPlayTones()<br />
same =&gt; n,SayUnixTime(,Europe/Bucharest,H)<br />
same =&gt; n,Wait(0.3)<br />
same =&gt; n,SayUnixTime(,Europe/Bucharest,M)<br />
same =&gt; n,Playback(minutes)<br />
same =&gt; n,SayUnixTime(,Europe/Bucharest,S)<br />
same =&gt; n,Playback(seconds)<br />
same =&gt; n,Wait(3)<br />
same =&gt; n,Goto(loop)</p>
<p>exten =&gt; s,1,Goto(958,1)</p>
<p>&nbsp;</p>
<p>then reload the dialplan:</p>
<p><em>sudo asterisk -rx &#8220;dialplan reload&#8221;</em></p>
<p>&nbsp;</p>
<p>There you go! Now just dial 958 from any phone on the PBX and enjoy the old times <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f642.png" alt="🙂" class="wp-smiley" style="height: 1em; max-height: 1em;" /></p>
<p>&nbsp;</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">375922</post-id>	</item>
		<item>
		<title>[LINUX] Create your own IP Radio Station</title>
		<link>https://www.pbnet.ro/?p=368987</link>
		
		<dc:creator><![CDATA[Andrei Rachita]]></dc:creator>
		<pubDate>Fri, 02 Jan 2026 19:51:14 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<guid isPermaLink="false">https://www.pbnet.ro/?p=368987</guid>

					<description><![CDATA[OK, so the idea of this post is to create a self-hosted low-bandwidth radio station, that can even work on 33.6Kbps modems. So, let&#8217;s start <a class="mh-excerpt-more" href="https://www.pbnet.ro/?p=368987" title="[LINUX] Create your own IP Radio Station">[...]</a>]]></description>
										<content:encoded><![CDATA[<p>OK, so the idea of this post is to create a self-hosted low-bandwidth radio station, that can even work on 33.6Kbps modems.</p>
<p>So, let&#8217;s start with:</p>
<ol>
<li>Hardware</li>
</ol>
<p>1 x vCPU</p>
<p>2 GB of RAM</p>
<p>128 GB Storage</p>
<p style="padding-left: 40px;">2. Software and configs</p>
<ul>
<li>OS: Ubuntu Server 24.04.3 LTS</li>
<li>IceCast</li>
</ul>
<p><em>sudo apt update</em><br />
<em>sudo apt -y upgrade</em><br />
<em>sudo apt install -y icecast2</em></p>
<ul>
<li>enable IceCast daemon</li>
</ul>
<p><em>sudo nano /etc/default/icecast2</em></p>
<p><strong><em>ENABLE=true</em></strong></p>
<ul>
<li>verify settings on IceCast&#8217;s main config file</li>
</ul>
<p><em>sudo nano /etc/icecast2/icecast.xml</em></p>
<ul>
<li>Start Icecast + enable on boot</li>
</ul>
<p><em>sudo systemctl enable &#8211;now icecast2</em><br />
<em>sudo systemctl status icecast2 &#8211;no-pager</em></p>
<p>&nbsp;</p>
<ul>
<li>Open the IceCast web page</li>
</ul>
<p>From your PC browser:</p>
<p>http://YOUR_SERVER_IP:8000/</p>
<p>Admin page:</p>
<p>http://YOUR_SERVER_IP:8000/admin/</p>
<p>user: admin</p>
<p>password: whatever you set as &lt;admin-password&gt;</p>
<ul>
<li>Create the music folder + IceCast user</li>
</ul>
<p><em>sudo adduser &#8211;system &#8211;group &#8211;no-create-home icecast</em></p>
<p><em>sudo mkdir -p /srv/radio/music</em><br />
<em>sudo chown -R icecast:icecast /srv/radio</em></p>
<p><em>sudo systemctl restart icecast2</em></p>
<ul>
<li>Install Liquidsoap</li>
</ul>
<p><em>sudo apt update</em><br />
<em>sudo apt install -y liquidsoap</em></p>
<p>Test install using: liquidsoap &#8211;version</p>
<ul>
<li>Create the Radio script</li>
</ul>
<p><em>sudo nano /srv/radio/radio.liq</em></p>
<p>Config sample:</p>
<p>&nbsp;</p>
<p><em>set(&#8220;log.stdout&#8221;, true)</em><br />
<em>set(&#8220;log.level&#8221;, 3)</em></p>
<p><em># Folder-based playlist</em><br />
<em>music = playlist(</em><br />
<em>&#8220;/srv/radio/music&#8221;,</em><br />
<em>mode=&#8221;random&#8221;,</em><br />
<em>reload=10</em><br />
<em>)</em></p>
<p><em># Output to Icecast (dial-up safe)</em><br />
<em>output.icecast(</em><br />
<em>%mp3(</em><br />
<em>bitrate=24,</em><br />
<em>samplerate=22050,</em><br />
<em>stereo=false</em><br />
<em>),</em><br />
<em>host=&#8221;localhost&#8221;,</em><br />
<em>port=8000,</em><br />
<em>password=&#8221;SOURCE_PASSWORD_HERE&#8221;,</em><br />
<em>mount=&#8221;/low.mp3&#8243;,</em><br />
<em>music</em><br />
<em>)</em></p>
<p>You can test the config manually: liquidsoap /srv/radio/radio.liq and you should see an output like:</p>
<p>Connecting mount /low.mp3<br />
Source connected</p>
<p>Add / remove music (live, no restart)</p>
<p>Just copy files into:</p>
<p>/srv/radio/music</p>
<ul>
<li>Run Liquidsoap automatically (systemd service)</li>
</ul>
<p><em>sudo nano /etc/systemd/system/radio.service</em></p>
<p><em>[Unit]</em><br />
<em>Description=Icecast Radio (Liquidsoap)</em><br />
<em>After=network-online.target icecast2.service</em><br />
<em>Wants=network-online.target</em></p>
<p><em>[Service]</em><br />
<em>User=icecast</em><br />
<em>Group=icecast</em><br />
<em>ExecStart=/usr/bin/liquidsoap /srv/radio/radio.liq</em><br />
<em>Restart=always</em><br />
<em>RestartSec=3</em></p>
<p><em>[Install]</em><br />
<em>WantedBy=multi-user.target</em></p>
<p>&nbsp;</p>
<p>Then enable it using:</p>
<p><em>sudo systemctl daemon-reload</em><br />
<em>sudo systemctl enable &#8211;now radio.service</em></p>
<p>&nbsp;</p>
<ul>
<li>Confirm the stream is LIVE on Icecast</li>
</ul>
<p>curl -I http://127.0.0.1:8000/low.mp3</p>
<p>You want to see HTTP/1.0 200 OK (or 200).</p>
<p>From your PC:</p>
<p>Open: http://YOUR_SERVER_IP:8000/low.mp3 in VLC or browser.</p>
<p>&nbsp;</p>
<ul>
<li>Install an HTML audio player page</li>
</ul>
<p><em>sudo apt install -y apache2</em><br />
<em>sudo ufw allow 80/tcp</em></p>
<p>&nbsp;</p>
<p><em>sudo nano /var/www/html/player.html</em></p>
<p>&nbsp;</p>
<p><em>&lt;!doctype html&gt;</em><br />
<em>&lt;html&gt;</em><br />
<em>&lt;head&gt;</em><br />
<em>&lt;meta charset=&#8221;utf-8&#8243;&gt;</em><br />
<em>&lt;title&gt;DialRadio&lt;/title&gt;</em><br />
<em>&lt;/head&gt;</em><br />
<em>&lt;body&gt;</em><br />
<em>&lt;h1&gt;DialRadio (24 kbps)&lt;/h1&gt;</em></p>
<p><em>&lt;audio controls preload=&#8221;none&#8221;&gt;</em><br />
<em>&lt;source src=&#8221;http://VM_LAN_IP:8000/low.mp3&#8243; type=&#8221;audio/mpeg&#8221;&gt;</em><br />
<em>Your browser does not support audio.</em><br />
<em>&lt;/audio&gt;</em></p>
<p><em>&lt;p&gt;Click <img src="https://s.w.org/images/core/emoji/17.0.2/72x72/25b6.png" alt="▶" class="wp-smiley" style="height: 1em; max-height: 1em;" /> Play to start the stream.&lt;/p&gt;</em><br />
<em>&lt;/body&gt;</em><br />
<em>&lt;/html&gt;</em></p>
<ul>
<li>Apache Redirects</li>
</ul>
<p>Goal: to redirect from: http://&lt;your server IP&gt; to: http://&lt;your server IP&gt;/player.html</p>
<p>&nbsp;</p>
<p><em>sudo nano /etc/apache2/sites-available/000-default.conf</em></p>
<p>Inside &lt;VirtualHost *:80&gt;, add:</p>
<p><em>RedirectMatch ^/$ /player.html</em></p>
<p>Example:</p>
<p>&lt;VirtualHost *:80&gt;<br />
DocumentRoot /var/www/html</p>
<p>RedirectMatch ^/$ /player.html<br />
&lt;/VirtualHost&gt;</p>
<p>Save and restart:</p>
<p><em>sudo systemctl restart apache2</em></p>
<p>Now enjoy listening to your own radio station by accessing: http://&lt;your server IP&gt; !</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">368987</post-id>	</item>
		<item>
		<title>[PnP/CSOM] &#8211; Reprovision SiteAssets library in SPO</title>
		<link>https://www.pbnet.ro/?p=360892</link>
		
		<dc:creator><![CDATA[Andrei Rachita]]></dc:creator>
		<pubDate>Mon, 01 Sep 2025 11:01:18 +0000</pubDate>
				<category><![CDATA[Microsoft Technologies]]></category>
		<guid isPermaLink="false">https://www.pbnet.ro/?p=360892</guid>

					<description><![CDATA[OK, so here are several ways to re-provision the SiteAssets library on a SharePoint online site collection: Using PnP: [crayon-6a07556088bec118750100/] Using CSOM (no MFA): [crayon-6a07556088bf1227393503/] <a class="mh-excerpt-more" href="https://www.pbnet.ro/?p=360892" title="[PnP/CSOM] &#8211; Reprovision SiteAssets library in SPO">[...]</a>]]></description>
										<content:encoded><![CDATA[<p>OK, so here are several ways to re-provision the SiteAssets library on a SharePoint online site collection:</p>
<p><strong>Using PnP:</strong></p><pre class="crayon-plain-tag">Connect-PnPOnline -Url https://pbnet.sharepoint.com/teams/ASSETS1 `
  -ClientId &quot;dfbd77ff-be64-XXX-XXX-17a62a02fd29&quot; `
  -Tenant &quot;pbnet.onmicrosoft.com&quot; `
  -CertificatePath &quot;C:\SPOPNP\pnpappcert.pfx&quot; `
  -CertificatePassword (ConvertTo-SecureString &quot;XXXXXXXXXX&quot; -AsPlainText -Force)

$Web = Get-PnPWeb
$Web.Lists.EnsureSiteAssetsLibrary()
Invoke-PnPQuery</pre><p><strong>Using CSOM (no MFA):</strong></p><pre class="crayon-plain-tag">Add-Type -Path &quot;C:\CSOM\Microsoft.SharePoint.Client.dll&quot;
Add-Type -Path &quot;C:\CSOM\Microsoft.SharePoint.Client.Runtime.dll&quot;
 
 
# SharePoint site and credentials
$siteUrl = &quot;https://a830edad9050849testasset.sharepoint.com/sites/SITEASSETS1&quot;
$username = &quot;admin@a830edad9050849testasset.onmicrosoft.com&quot;
 
# Get credentials
$securePassword = Read-Host -Prompt &quot;Enter your password&quot; -AsSecureString
$credentials = New-Object Microsoft.SharePoint.Client.SharePointOnlineCredentials($username, $securePassword)
 
# Connect to SharePoint
$context = New-Object Microsoft.SharePoint.Client.ClientContext($siteUrl)
$context.Credentials = $credentials
 
# Get the list and root folder
$t = $context.Web.Lists.EnsureSiteAssetsLibrary()
$context.Load($t)
 
$context.ExecuteQuery()</pre><p><strong>Using CSOM with MFA</strong> (you can use my DLL set from: <a href="https://www.pbnet.ro/tools_dl/CSOM-27JAN2020.zip" target="_blank" rel="noopener">https://www.pbnet.ro/tools_dl/CSOM-27JAN2020.zip</a></p><pre class="crayon-plain-tag">#Loading Assemblies
[System.Reflection.Assembly]::LoadFile(&quot;C:\CSOM\Microsoft.SharePoint.Client.dll&quot;)
[System.Reflection.Assembly]::LoadFile(&quot;C:\CSOM\Microsoft.SharePoint.Client.Runtime.dll&quot;)
[System.Reflection.Assembly]::LoadFile(&quot;C:\CSOM\\Microsoft.SharePoint.Client.Publishing.dll&quot;)
#download https://www.nuget.org/packages/Microsoft.IdentityModel.Clients.ActiveDirectory/3.19.8 
[System.Reflection.Assembly]::LoadFile(&quot;C:\CSOM\Microsoft.IdentityModel.Clients.ActiveDirectory.dll&quot;)
#download https://www.nuget.org/packages/SharePointPnPCoreOnline/3.26.2010
[System.Reflection.Assembly]::LoadFile(&quot;C:\CSOM\OfficeDevPnP.Core.dll&quot;)

$siteURL=&quot;https://pbnet.sharepoint.com/teams/ASSETS1&quot;
 $authManager = new-object OfficeDevPnP.Core.AuthenticationManager;
$context = $authManager.GetWebLoginClientContext($siteUrl);

# Get the list and root folder
$t = $context.Web.Lists.EnsureSiteAssetsLibrary()
$context.Load($t)
 
$context.ExecuteQuery()</pre><p>Or, another way to re-provision the Assets library would be by Enabling the WikiPageHomePage feature on the site collection</p>
<p><strong>Using PnP:</strong></p><pre class="crayon-plain-tag">#Disable WikiPageHomePage
Disable-PnPFeature -Identity 00bfea71-d8fe-4fec-8dad-01c19a6e4053
#Enable WikiPageHomePage
Enable-PnPFeature -Identity 00bfea71-d8fe-4fec-8dad-01c19a6e4053</pre><p>Enjoy!</p>
<p>&nbsp;</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">360892</post-id>	</item>
		<item>
		<title>[LINUX] Remote Login using Apache Guacamole</title>
		<link>https://www.pbnet.ro/?p=360380</link>
		
		<dc:creator><![CDATA[Andrei Rachita]]></dc:creator>
		<pubDate>Mon, 25 Aug 2025 06:52:50 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<category><![CDATA[Networking]]></category>
		<guid isPermaLink="false">https://www.pbnet.ro/?p=360380</guid>

					<description><![CDATA[Apache Guacamole is a clientless remote desktop gateway. It supports standard protocols like VNC, RDP, and SSH. It is clientless because no plugins or client <a class="mh-excerpt-more" href="https://www.pbnet.ro/?p=360380" title="[LINUX] Remote Login using Apache Guacamole">[...]</a>]]></description>
										<content:encoded><![CDATA[<p>Apache Guacamole is a clientless remote desktop gateway. It supports standard protocols like VNC, RDP, and SSH.</p>
<p>It is clientless because no plugins or client software are required.</p>
<p>Thanks to HTML5, once Guacamole is installed on a server, all you need to access your desktops is a web browser.</p>
<p>Below I&#8217;m going to discuss how to install Guacamole and it&#8217;s TOTP module (aka login with 2FA) on Ubuntu 24.04.3 LTS.</p>
<p><strong>Understanding the pieces:</strong></p>
<p>guacamole-server (aka guacd) = native daemon that speaks RDP/VNC/SSH, must be built from source.</p>
<p>guacamole web app = a .war deployed to Tomcat (we’ll use Tomcat 9).</p>
<p>Auth = we’ll use MariaDB (JDBC extension).<br />
Guacamole 1.6.0 provides the WAR + JDBC extension prebuilt; only guacamole-server is compiled.</p>
<p><strong>Packages &amp; build dependencies</strong></p><pre class="crayon-plain-tag">sudo apt update
sudo apt install -y build-essential autoconf automake libtool-bin \
  libcairo2-dev libjpeg-turbo8-dev libpng-dev uuid-dev libssl-dev \
  libavcodec-dev libavformat-dev libavutil-dev libswscale-dev \
  libpango1.0-dev libssh2-1-dev libtelnet-dev libvncserver-dev \
  libwebsockets-dev libpulse-dev libvorbis-dev libwebp-dev \
  freerdp3-dev wget curl fonts-dejavu-core</pre><p><strong> Build and start <em>guacd</em> (guacamole-server 1.6.0)</strong></p><pre class="crayon-plain-tag">cd /usr/src
sudo wget https://downloads.apache.org/guacamole/1.6.0/source/guacamole-server-1.6.0.tar.gz
sudo tar xzf guacamole-server-1.6.0.tar.gz
cd guacamole-server-1.6.0

# The systemd dir below is correct for Ubuntu; the FreeRDP flag keeps things lenient.
sudo ./configure --with-systemd-dir=/etc/systemd/system --enable-allow-freerdp-snapshots
sudo make -j&quot;$(nproc)&quot;
sudo make install
sudo ldconfig

# Register and start the service
sudo systemctl daemon-reload
sudo systemctl enable --now guacd
systemctl status guacd --no-pager</pre><p><strong>Install Java and Tomcat 9 (not Tomcat 10)</strong></p>
<p>Note: Guacamole 1.x targets the javax servlet APIs (Tomcat 9). Tomcat 10 switched to jakarta and isn’t supported yet.</p><pre class="crayon-plain-tag"># Java (LTS)
sudo apt install -y openjdk-17-jdk

# Create a dedicated tomcat user
sudo useradd -m -U -d /opt/tomcat -s /bin/false tomcat

# Download &amp;amp; install Tomcat 9 (set the latest 9.0.x available)
TOMCAT_VER=9.0.108
cd /tmp
wget https://dlcdn.apache.org/tomcat/tomcat-9/v${TOMCAT_VER}/bin/apache-tomcat-${TOMCAT_VER}.tar.gz
sudo mkdir -p /opt/tomcat
sudo tar xzf apache-tomcat-${TOMCAT_VER}.tar.gz -C /opt/tomcat --strip-components=1
sudo chown -R tomcat:tomcat /opt/tomcat

# Tell Tomcat where GUACAMOLE_HOME lives
sudo bash -c 'cat &amp;gt;/opt/tomcat/bin/setenv.sh &amp;lt;&amp;lt;EOF
export JAVA_HOME=$(dirname $(dirname $(readlink -f $(which java))))
export GUACAMOLE_HOME=/etc/guacamole
EOF'
sudo chmod +x /opt/tomcat/bin/setenv.sh

# Systemd unit for Tomcat 9
sudo tee /etc/systemd/system/tomcat.service &amp;gt;/dev/null &amp;lt;&amp;lt;'EOF'
[Unit]
Description=Apache Tomcat 9
After=network.target

[Service]
Type=forking
User=tomcat
Group=tomcat
UMask=0007
Environment=CATALINA_BASE=/opt/tomcat
Environment=CATALINA_HOME=/opt/tomcat
Environment=CATALINA_PID=/opt/tomcat/temp/tomcat.pid
ExecStart=/opt/tomcat/bin/startup.sh
ExecStop=/opt/tomcat/bin/shutdown.sh
Restart=on-failure

[Install]
WantedBy=multi-user.target
EOF

sudo systemctl daemon-reload
sudo systemctl enable --now tomcat
systemctl status tomcat --no-pager</pre><p><strong>Prepare GUACAMOLE_HOME and deploy the 1.6.0 WAR</strong></p><pre class="crayon-plain-tag"># Config directories used by Guacamole/Tomcat
sudo mkdir -p /etc/guacamole/{extensions,lib}

# Basic properties so the webapp can reach guacd
sudo tee /etc/guacamole/guacamole.properties &amp;gt;/dev/null &amp;lt;&amp;lt;'EOF'
guacd-hostname: 127.0.0.1
guacd-port: 4822
EOF

# Deploy the 1.6.0 web app
sudo wget -O /opt/tomcat/webapps/guacamole.war \
  https://downloads.apache.org/guacamole/1.6.0/binary/guacamole-1.6.0.war

# Restart Tomcat to unpack the WAR
sudo systemctl restart tomcat</pre><p><strong>Install MariaDB and the JDBC auth extension</strong></p><pre class="crayon-plain-tag"># DB server
sudo apt install -y mariadb-server

# Create DB and user (change the password!)
DB_PASS='ChangeMe_Secure!'
sudo mysql -e &quot;CREATE DATABASE guacamole_db DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;&quot;
sudo mysql -e &quot;CREATE USER 'guacamole_user'@'localhost' IDENTIFIED BY '${DB_PASS}';&quot;
sudo mysql -e &quot;GRANT ALL PRIVILEGES ON guacamole_db.* TO 'guacamole_user'@'localhost'; FLUSH PRIVILEGES;&quot;

# JDBC extension (MySQL/MariaDB flavor)
cd /usr/src
sudo wget https://downloads.apache.org/guacamole/1.6.0/binary/guacamole-auth-jdbc-1.6.0.tar.gz
sudo tar xzf guacamole-auth-jdbc-1.6.0.tar.gz
sudo cp guacamole-auth-jdbc-1.6.0/mysql/guacamole-auth-jdbc-mysql-1.6.0.jar /etc/guacamole/extensions/

# Initialize the schema
cd guacamole-auth-jdbc-1.6.0/mysql
sudo bash -lc &quot;cat schema/*.sql | mysql -u root guacamole_db&quot;

# JDBC driver (Connector/J 8.4 LTS JAR)
sudo wget -O /etc/guacamole/lib/mysql-connector-j-8.4.0.jar \
  https://repo1.maven.org/maven2/com/mysql/mysql-connector-j/8.4.0/mysql-connector-j-8.4.0.jar

# Point Guacamole at the database
sudo tee -a /etc/guacamole/guacamole.properties &amp;gt;/dev/null &amp;lt;&amp;lt;EOF

# --- JDBC auth (MariaDB/MySQL) ---
mysql-hostname: 127.0.0.1
mysql-port: 3306
mysql-database: guacamole_db
mysql-username: guacamole_user
mysql-password: ${DB_PASS}
# Explicit driver class for Connector/J 8+
mysql-driver: com.mysql.cj.jdbc.Driver
EOF

# Bounce services
sudo systemctl restart guacd tomcat</pre><p><strong>Log in and secure it</strong></p>
<ul>
<li data-start="6034" data-end="6081">
<p data-start="6036" data-end="6081">rowse to: <code data-start="6047" data-end="6079">http://&lt;server&gt;:8080/guacamole</code></p>
</li>
<li data-start="6082" data-end="6293">
<p data-start="6084" data-end="6293"><strong data-start="6084" data-end="6101">Default admin</strong> (created by the schema): <code data-start="6127" data-end="6138">guacadmin</code> / <code data-start="6141" data-end="6152">guacadmin</code> → change it immediately (Settings → Preferences), then create your own admin and delete <code data-start="6241" data-end="6252">guacadmin</code>.</p>
</li>
</ul>
<p>Now, let&#8217;s install and the TOTP Module:</p>
<p><strong>Download + verify (from Apache archive)</strong></p><pre class="crayon-plain-tag">cd /tmp
curl -fL -o guacamole-auth-totp-1.6.0.tar.gz \
  https://archive.apache.org/dist/guacamole/1.6.0/binary/guacamole-auth-totp-1.6.0.tar.gz
curl -fsSL -o guacamole-auth-totp-1.6.0.tar.gz.sha256 \
  https://archive.apache.org/dist/guacamole/1.6.0/binary/guacamole-auth-totp-1.6.0.tar.gz.sha256

# must say: &ldquo;guacamole-auth-totp-1.6.0.tar.gz: OK&rdquo;
sha256sum -c guacamole-auth-totp-1.6.0.tar.gz.sha256</pre><p><strong>Install the extension jar</strong></p><pre class="crayon-plain-tag">tar -xzf guacamole-auth-totp-1.6.0.tar.gz
sudo install -D -m 0644 guacamole-auth-totp-1.6.0/guacamole-auth-totp-1.6.0.jar \
  /etc/guacamole/extensions/guacamole-auth-totp-1.6.0.jar

ls -l /etc/guacamole/extensions</pre><p><strong>Restart <em>Tomcat </em>(not guacd) and check logs</strong></p><pre class="crayon-plain-tag">sudo systemctl restart tomcat
# Confirm GUACAMOLE_HOME and TOTP load:
grep -i 'GUACAMOLE_HOME is' /opt/tomcat/logs/catalina.out | tail -n1
egrep -i 'Extension &quot;TOTP Authentication&quot;|totp' /opt/tomcat/logs/catalina.out | tail -n2</pre><p>If it loaded, you’ll see something like:</p>
<p><em>Extension &#8220;TOTP Authentication&#8221; (totp) loaded.</em></p>
<p>&nbsp;</p>
<p>Enjoy!</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">360380</post-id>	</item>
		<item>
		<title>[SPO/PNP] Connect to SharePoint online using PNP and a self-signed certificate</title>
		<link>https://www.pbnet.ro/?p=356933</link>
		
		<dc:creator><![CDATA[Andrei Rachita]]></dc:creator>
		<pubDate>Wed, 21 May 2025 09:38:25 +0000</pubDate>
				<category><![CDATA[Microsoft Technologies]]></category>
		<guid isPermaLink="false">https://www.pbnet.ro/?p=356933</guid>

					<description><![CDATA[Since the 3.0.x version of the PNP module, you don&#8217;t have the -UseWebLogin switch anymore when using Connect-PnPOnline. So, let&#8217;s connect using a self-signed certificate <a class="mh-excerpt-more" href="https://www.pbnet.ro/?p=356933" title="[SPO/PNP] Connect to SharePoint online using PNP and a self-signed certificate">[...]</a>]]></description>
										<content:encoded><![CDATA[<p>Since the 3.0.x version of the PNP module, you don&#8217;t have the -UseWebLogin switch anymore when using Connect-PnPOnline.</p>
<p>So, let&#8217;s connect using a self-signed certificate instead.</p>
<p>Here&#8217;s how to do it:</p>
<ol>
<li><strong>Create a self-signed certificate:</strong></li>
</ol>
<p><em>Note: you need to have the PNP.PowerShell module installed before running the below cmdlets. </em></p><pre class="crayon-plain-tag">$cert = New-PnPAzureCertificate -OutPfx pnpappcert.pfx -OutCert pnpappcert.cer -CertificatePassword (ConvertTo-SecureString -String &quot;YourStrongPassword&quot; -AsPlainText -Force)</pre><p>This command creates:</p>
<p><em>pnpappcert.pfx: the private certificate used by your script</em></p>
<p><em>pnpappcert.cer: the public certificate to upload to Entra ID</em></p>
<p>Note: The password is required later to use the .pfx</p>
<p>&nbsp;</p>
<p style="padding-left: 40px;"><strong>2. Register an app in Entra ID </strong></p>
<ul>
<li>Go to: https://entra.microsoft.com</li>
<li>Navigate to “App registrations” &gt; “New registration”</li>
</ul>
<p>Fill in:</p>
<p>Name: PnPApp</p>
<p>Supported account types: Single tenant is OK</p>
<p>Redirect URI: Leave blank for now</p>
<p>Click Register</p>
<p>&nbsp;</p>
<p style="padding-left: 40px;"><strong>3. Upload the Public Certificate to the App</strong></p>
<p>&nbsp;</p>
<p>In the app registration panel:</p>
<p>Go to Certificates &amp; secrets</p>
<p>Choose Certificates (Upload) → Upload pnpappcert.cer</p>
<p>&nbsp;</p>
<p style="padding-left: 40px;"><strong>4. Assign API Permissions</strong></p>
<p>&nbsp;</p>
<ul>
<li class="" data-start="1355" data-end="1614">
<p class="" data-start="1358" data-end="1382">In the app registration:</p>
<ul data-start="1386" data-end="1614">
<li class="" data-start="1386" data-end="1413">
<p class="" data-start="1388" data-end="1413">Go to <strong data-start="1394" data-end="1413">API permissions</strong></p>
</li>
<li class="" data-start="1417" data-end="1445">
<p class="" data-start="1419" data-end="1445">Click <strong data-start="1425" data-end="1445">Add a permission</strong></p>
</li>
<li class="" data-start="1449" data-end="1502">
<p class="" data-start="1451" data-end="1502">Choose <strong data-start="1458" data-end="1472">SharePoint</strong> &gt; <strong data-start="1475" data-end="1502">Application permissions</strong></p>
</li>
<li class="" data-start="1506" data-end="1583">
<p class="" data-start="1508" data-end="1514">Check:</p>
<ul data-start="1520" data-end="1583">
<li class="" data-start="1520" data-end="1538">
<p class="" data-start="1522" data-end="1538"><code data-start="1522" data-end="1538">Sites.Read.All</code></p>
</li>
<li class="" data-start="1544" data-end="1583">
<p class="" data-start="1546" data-end="1583"><code data-start="1546" data-end="1569">Sites.FullControl.All</code> <em data-start="1570" data-end="1583">(if needed)</em></p>
</li>
</ul>
</li>
<li class="" data-start="1587" data-end="1614">
<p class="" data-start="1589" data-end="1614">Click <strong data-start="1595" data-end="1614">Add permissions</strong></p>
</li>
</ul>
</li>
<li class="" data-start="1615" data-end="1652">
<p class="" data-start="1618" data-end="1652">Then click <strong data-start="1629" data-end="1652">Grant admin consent</strong></p>
</li>
</ul>
<p><em>Note: you can grant additional permissions. Here&#8217;s a screenshot of what I used:</em></p>
<p><a href="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/05/Screenshot-2025-05-21-123513.png?ssl=1"><img data-recalc-dims="1" fetchpriority="high" decoding="async" data-attachment-id="356934" data-permalink="https://www.pbnet.ro/?attachment_id=356934" data-orig-file="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/05/Screenshot-2025-05-21-123513.png?fit=1989%2C838&amp;ssl=1" data-orig-size="1989,838" data-comments-opened="1" data-image-meta="{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}" data-image-title="Screenshot 2025-05-21 123513" data-image-description="" data-image-caption="" data-large-file="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/05/Screenshot-2025-05-21-123513.png?fit=678%2C285&amp;ssl=1" class="alignnone  wp-image-356934" src="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/05/Screenshot-2025-05-21-123513.png?resize=678%2C285&#038;ssl=1" alt="App Permissions" width="678" height="285" srcset="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/05/Screenshot-2025-05-21-123513.png?resize=1024%2C431&amp;ssl=1 1024w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/05/Screenshot-2025-05-21-123513.png?resize=300%2C126&amp;ssl=1 300w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/05/Screenshot-2025-05-21-123513.png?resize=768%2C324&amp;ssl=1 768w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/05/Screenshot-2025-05-21-123513.png?resize=1536%2C647&amp;ssl=1 1536w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/05/Screenshot-2025-05-21-123513.png?w=1989&amp;ssl=1 1989w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/05/Screenshot-2025-05-21-123513.png?w=1356&amp;ssl=1 1356w" sizes="(max-width: 678px) 100vw, 678px" /></a></p>
<p>&nbsp;</p>
<p style="padding-left: 40px;"><strong>5. Connect using you certificate and APPId</strong></p>
<p>&nbsp;</p><pre class="crayon-plain-tag">Connect-PnPOnline -Url &quot;https://yourtenant.sharepoint.com/sites/yoursite&quot; `
  -ClientId &quot;YOUR-APP-ID&quot; `
  -Tenant &quot;yourtenant.onmicrosoft.com&quot; `
  -CertificatePath &quot;C:\Path\To\pnpappcert.pfx&quot; `
  -CertificatePassword (ConvertTo-SecureString &quot;YourStrongPassword&quot; -AsPlainText -Force)</pre><p>Enjoy!</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">356933</post-id>	</item>
		<item>
		<title>[LINUX] WHOIS server retirement</title>
		<link>https://www.pbnet.ro/?p=356778</link>
		
		<dc:creator><![CDATA[Andrei Rachita]]></dc:creator>
		<pubDate>Thu, 15 May 2025 15:50:19 +0000</pubDate>
				<category><![CDATA[Linux]]></category>
		<guid isPermaLink="false">https://www.pbnet.ro/?p=356778</guid>

					<description><![CDATA[So, if you&#8217;re using the WHOIS command under linux (E.g whois rachita.net), you will probably get some notice like: **NOTICE** This WHOIS server is being <a class="mh-excerpt-more" href="https://www.pbnet.ro/?p=356778" title="[LINUX] WHOIS server retirement">[...]</a>]]></description>
										<content:encoded><![CDATA[<p>So, if you&#8217;re using the WHOIS command under linux (E.g whois rachita.net), you will probably get some notice like:<br />
<em>**NOTICE** This WHOIS server is being retired. Please use our RDAP service instead.</em></p>
<p>In a nutshell, this is why it happens:</p>
<p>The long-standing WHOIS system for looking up domain name registration details is coming to an end. Starting January 28, 2025, ICANN will officially replace WHOIS with the Registration Data Access Protocol (RDAP). But don’t worry—this change isn’t happening overnight, and most users won’t notice any immediate disruptions.</p>
<p>RDAP is a modern alternative to WHOIS that offers several improvements:</p>
<ul class="wp-block-list">
<li><strong>better security:</strong> it provides more controlled access to domain registration data.</li>
<li><strong>international support:</strong> unlike WHOIS, RDAP supports multiple languages and character sets.</li>
<li><strong>structured data:</strong> it delivers information in a standardized format, making it easier to process.</li>
<li><strong>more control over data:</strong> RDAP allows differentiated access, meaning some users (like law enforcement) may see more details than the general public.</li>
</ul>
<p>ICANN-accredited registrars and gTLDs have already supported RDAP since 2019, so the transition has been in the works for a while.</p>
<p>Source: <a href="https://www.icann.org/en/announcements/details/icann-update-launching-rdap-sunsetting-whois-27-01-2025-en" target="_blank" rel="noopener">https://www.icann.org/en/announcements/details/icann-update-launching-rdap-sunsetting-whois-27-01-2025-en</a></p>
<p>So let&#8217;s use the RDAP service.</p>
<p>You will need a RDAP client. Here&#8217;s how to install it:</p>
<h2 class="" data-start="254" data-end="272">Requirements</h2>
<ul data-start="274" data-end="344">
<li class="" data-start="274" data-end="302">
<p class="" data-start="276" data-end="302">Ubuntu/Debian-based system</p>
</li>
<li class="" data-start="303" data-end="310">
<p class="" data-start="305" data-end="310"><code data-start="305" data-end="310">git</code></p>
</li>
<li class="" data-start="311" data-end="344">
<p class="" data-start="313" data-end="344"><code data-start="313" data-end="321">golang</code> (Go language compiler)</p>
</li>
</ul>
<p>&nbsp;</p>
<h2 class="" data-start="351" data-end="382">Step-by-Step Installation</h2>
<h3 class="" data-start="384" data-end="412"><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f539.png" alt="🔹" class="wp-smiley" style="height: 1em; max-height: 1em;" /> 1. Install Go and Git</h3>
<div class="contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary">
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre! language-bash">sudo apt update</code></div>
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre! language-bash">sudo apt install golang-go git -y<br />
</code></div>
</div>
<blockquote data-start="477" data-end="590">
<p class="" data-start="479" data-end="590"><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f4dd.png" alt="📝" class="wp-smiley" style="height: 1em; max-height: 1em;" /> This installs Go from Ubuntu repositories. For newer versions, visit: <a class="cursor-pointer" target="_new" rel="noopener" data-start="552" data-end="590">https://go.dev/dl</a></p>
</blockquote>
<hr class="" data-start="592" data-end="595" />
<h3 class="" data-start="597" data-end="636"><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f539.png" alt="🔹" class="wp-smiley" style="height: 1em; max-height: 1em;" /> 2. Clone the OpenRDAP repository</h3>
<div class="contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary">
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre! language-bash"><span class="hljs-built_in">cd</span> ~<br />
</code></div>
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre! language-bash">git <span class="hljs-built_in">clone</span> https://github.com/openrdap/rdap.git<br />
</code></div>
</div>
<hr class="" data-start="703" data-end="706" />
<h3 class="" data-start="708" data-end="756"><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f539.png" alt="🔹" class="wp-smiley" style="height: 1em; max-height: 1em;" /> 3. Navigate to the RDAP CLI source folder</h3>
<div class="contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary">
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre! language-bash"><span class="hljs-built_in">cd</span> ~/rdap/cmd/rdap<br />
</code></div>
</div>
<p class="" data-start="790" data-end="822">Check that <code data-start="801" data-end="810">main.go</code> is present:</p>
<div class="contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary">
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre! language-bash"><span class="hljs-built_in">ls</span> main.go<br />
</code></div>
</div>
<hr class="" data-start="848" data-end="851" />
<h3 class="" data-start="853" data-end="886"><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f539.png" alt="🔹" class="wp-smiley" style="height: 1em; max-height: 1em;" /> 4. Build the <code data-start="873" data-end="879">rdap</code> binary</h3>
<div class="contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary">
<div class="sticky top-9">
<div class="absolute end-0 bottom-0 flex h-9 items-center pe-2">
<div class="bg-token-sidebar-surface-primary text-token-text-secondary dark:bg-token-main-surface-secondary flex items-center rounded-sm px-2 font-sans text-xs"></div>
</div>
</div>
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre! language-bash">go build -o rdap<br />
</code></div>
</div>
<p class="" data-start="918" data-end="965">You should now have a binary file named <code data-start="958" data-end="964">rdap</code>.</p>
<p class="" data-start="967" data-end="1000">Check it&#8217;s a proper Linux binary:</p>
<div class="contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary">
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre! language-bash">file rdap<br />
</code></div>
</div>
<p class="" data-start="1025" data-end="1041">Expected output:</p>
<div class="contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary">
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre!">rdap: ELF <span class="hljs-number">64</span>-bit LSB executable, x86<span class="hljs-number">-64</span> ...<br />
</code></div>
</div>
<hr class="" data-start="1096" data-end="1099" />
<h3 class="" data-start="1101" data-end="1139"><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f539.png" alt="🔹" class="wp-smiley" style="height: 1em; max-height: 1em;" /> 5. Move the binary to your PATH</h3>
<div class="contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary">
<div class="sticky top-9">
<div class="absolute end-0 bottom-0 flex h-9 items-center pe-2">
<div class="bg-token-sidebar-surface-primary text-token-text-secondary dark:bg-token-main-surface-secondary flex items-center rounded-sm px-2 font-sans text-xs"></div>
</div>
</div>
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre! language-bash">sudo <span class="hljs-built_in">mv</span> rdap /usr/local/bin/</code></div>
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre! language-bash">sudo <span class="hljs-built_in">chmod</span> +x /usr/local/bin/rdap<br />
</code></div>
</div>
<hr class="" data-start="1217" data-end="1220" />
<h3 class="" data-start="1222" data-end="1252"><img src="https://s.w.org/images/core/emoji/17.0.2/72x72/1f539.png" alt="🔹" class="wp-smiley" style="height: 1em; max-height: 1em;" /> 6. Test the RDAP client</h3>
<div class="contain-inline-size rounded-md border-[0.5px] border-token-border-medium relative bg-token-sidebar-surface-primary">
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre! language-bash">rdap 8.8.8.8<br />
</code></div>
<div class="overflow-y-auto p-4" dir="ltr"><code class="whitespace-pre! language-bash">rdap example.com</code></div>
</div>
<div dir="ltr"></div>
<div dir="ltr">The output should look like this:</div>
<div dir="ltr"></div>
<div dir="ltr">
<pre class="crayon-plain-tag">IP Network:
  Handle: NET-8-8-8-0-2
  Start Address: 8.8.8.0
  End Address: 8.8.8.255
  IP Version: v4
  Name: GOGL
  Type: DIRECT ALLOCATION
  ParentHandle: NET-8-0-0-0-0
  Status: active
  Port43: whois.arin.net
  Notice:
    Title: Terms of Service
    Description: By using the ARIN RDAP/Whois service, you are agreeing to the RDAP/Whois Terms of Use
    Link: https://www.arin.net/resources/registry/whois/tou/
  Notice:
    Title: Whois Inaccuracy Reporting
    Description: If you see inaccuracies in the results, please visit:
    Link: https://www.arin.net/resources/registry/whois/inaccuracy_reporting/
  Notice:
    Title: Copyright Notice
    Description: Copyright 1997-2025, American Registry for Internet Numbers, Ltd.
  Entity:
    Handle: GOGL
    Port43: whois.arin.net
    Remark:
      Title: Registration Comments
      Description: Please note that the recommended way to file abuse complaints are located in the following links.
      Description: To report abuse and illegal activity: https://www.google.com/contact/
      Description: For legal requests: http://support.google.com/legal
      Description: Regards,
      Description: The Google Team
    Link: https://rdap.arin.net/registry/entity/GOGL
    Link: https://whois.arin.net/rest/org/GOGL
    Event:
      Action: last changed
      Date: 2019-10-31T15:45:45-04:00
    Event:
      Action: registration
      Date: 2000-03-30T00:00:00-05:00
    Role: registrant
    vCard version: 4.0
    vCard fn: Google LLC
    vCard kind: org
    Entity:
      Handle: ABUSE5250-ARIN
      Status: validated
      Port43: whois.arin.net
      Remark:
        Title: Registration Comments
        Description: Please note that the recommended way to file abuse complaints are located in the following links.
        Description: To report abuse and illegal activity: https://www.google.com/contact/
        Description: For legal requests: http://support.google.com/legal
        Description: Regards,
        Description: The Google Team
      Link: https://rdap.arin.net/registry/entity/ABUSE5250-ARIN
      Link: https://whois.arin.net/rest/poc/ABUSE5250-ARIN
      Event:
        Action: last changed
        Date: 2024-08-01T17:54:23-04:00
      Event:
        Action: registration
        Date: 2015-11-06T15:36:35-05:00
      Role: abuse
      vCard version: 4.0
      vCard fn: Abuse
      vCard org: Abuse
      vCard kind: group
      vCard email: network-abuse@google.com
      vCard tel: +1-650-253-0000
    Entity:
      Handle: ZG39-ARIN
      Status: validated
      Port43: whois.arin.net
      Link: https://rdap.arin.net/registry/entity/ZG39-ARIN
      Link: https://whois.arin.net/rest/poc/ZG39-ARIN
      Event:
        Action: last changed
        Date: 2024-11-11T04:27:09-05:00
      Event:
        Action: registration
        Date: 2000-11-30T13:54:08-05:00
      Role: administrative
      Role: technical
      vCard version: 4.0
      vCard fn: Google LLC
      vCard org: Google LLC
      vCard kind: group
      vCard email: arin-contact@google.com
      vCard tel: +1-650-253-0000
  Link: https://rdap.arin.net/registry/ip/8.8.8.0
  Link: https://whois.arin.net/rest/net/NET-8-8-8-0-2
  Event:
    Action: last changed
    Date: 2023-12-28T17:24:56-05:00
  Event:
    Action: registration
    Date: 2023-12-28T17:24:33-05:00
  cidr0_cidrs:
    v4prefix: 8.8.8.0
    length: 24</pre><br />
Enjoy!</p>
<p>&nbsp;</p>
<p>&nbsp;</p>
</div>
<div dir="ltr"></div>
<div dir="ltr"></div>
<div dir="ltr"></div>
<div dir="ltr"></div>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">356778</post-id>	</item>
		<item>
		<title>[SPO] Remove retention tags for all the items (folders included) in a document library</title>
		<link>https://www.pbnet.ro/?p=356077</link>
		
		<dc:creator><![CDATA[Andrei Rachita]]></dc:creator>
		<pubDate>Mon, 14 Apr 2025 12:51:39 +0000</pubDate>
				<category><![CDATA[Microsoft Technologies]]></category>
		<guid isPermaLink="false">https://www.pbnet.ro/?p=356077</guid>

					<description><![CDATA[If you tagged all your files/folders in a document library with a retention label/tag, here&#8217;s a quick way to remove them via PnP: [crayon-6a0755608902b057327385/] Enjoy!]]></description>
										<content:encoded><![CDATA[<p>If you tagged all your files/folders in a document library with a retention label/tag, here&#8217;s a quick way to remove them via PnP:</p><pre class="crayon-plain-tag">Connect-PnPOnline -Url https://mngenvmcap495437.sharepoint.com/sites/RETENTION-TEST1 -UseWebLogin
$items = Get-PnPListItem -List &quot;Documents&quot;

foreach ($item in $items)

{

     Set-PnPListItem -Identity $item.Id -List &quot;Documents&quot; -ClearLabel

}</pre><p>Enjoy!</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">356077</post-id>	</item>
		<item>
		<title>[SPO] Get the filename, filetype and path from a SharePoint shared link URL</title>
		<link>https://www.pbnet.ro/?p=355555</link>
		
		<dc:creator><![CDATA[Andrei Rachita]]></dc:creator>
		<pubDate>Thu, 20 Mar 2025 16:35:32 +0000</pubDate>
				<category><![CDATA[Microsoft Technologies]]></category>
		<guid isPermaLink="false">https://www.pbnet.ro/?p=355555</guid>

					<description><![CDATA[OK, so the scenario goes like this: You go to a SharePoint document library, click on the ellipsis next to a file and select &#8220;Copy <a class="mh-excerpt-more" href="https://www.pbnet.ro/?p=355555" title="[SPO] Get the filename, filetype and path from a SharePoint shared link URL">[...]</a>]]></description>
										<content:encoded><![CDATA[<p>OK, so the scenario goes like this:</p>
<ul>
<li>You go to a SharePoint document library, click on the ellipsis next to a file and select &#8220;Copy Link&#8221;</li>
</ul>
<p><a href="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/CopyLink2032025.png?ssl=1"><img data-recalc-dims="1" decoding="async" data-attachment-id="355556" data-permalink="https://www.pbnet.ro/?attachment_id=355556" data-orig-file="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/CopyLink2032025.png?fit=765%2C597&amp;ssl=1" data-orig-size="765,597" data-comments-opened="1" data-image-meta="{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}" data-image-title="CopyLink2032025" data-image-description="" data-image-caption="" data-large-file="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/CopyLink2032025.png?fit=678%2C529&amp;ssl=1" class="alignnone wp-image-355556" src="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/CopyLink2032025.png?resize=531%2C414&#038;ssl=1" alt="" width="531" height="414" srcset="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/CopyLink2032025.png?w=765&amp;ssl=1 765w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/CopyLink2032025.png?resize=300%2C234&amp;ssl=1 300w" sizes="(max-width: 531px) 100vw, 531px" /></a></p>
<ul>
<li>you will get a URL like: https://pbnet.sharepoint.com/:b:/s/BLABLA1/EXZD4nQEQEpLv2pPl-btZnkB3FrKUYbP7jXCEveeY_WfYA?e=hJCcWh</li>
</ul>
<p>OK, now for the funny part, how can you know from that URL, what the file name is and where it is located.</p>
<p>If you use my tool: <a href="https://whois.pbnet.ro/SPOLINKDECODER/" target="_blank" rel="noopener">https://whois.pbnet.ro/SPOLINKDECODER/</a> you can already get some basic information like:</p>
<p><a href="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/toolInfo2032025.png?ssl=1"><img data-recalc-dims="1" decoding="async" data-attachment-id="355557" data-permalink="https://www.pbnet.ro/?attachment_id=355557" data-orig-file="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/toolInfo2032025.png?fit=765%2C446&amp;ssl=1" data-orig-size="765,446" data-comments-opened="1" data-image-meta="{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}" data-image-title="toolInfo2032025" data-image-description="" data-image-caption="" data-large-file="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/toolInfo2032025.png?fit=678%2C395&amp;ssl=1" class="alignnone size-full wp-image-355557" src="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/toolInfo2032025.png?resize=678%2C395&#038;ssl=1" alt="" width="678" height="395" srcset="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/toolInfo2032025.png?w=765&amp;ssl=1 765w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/toolInfo2032025.png?resize=300%2C175&amp;ssl=1 300w" sizes="(max-width: 678px) 100vw, 678px" /></a></p>
<p>For more information about the tool and what&#8217;s its logic, please see my GitHub page: <a href="https://github.com/pbnet/SharePointSharedLinkDecoder" target="_blank" rel="noopener">https://github.com/pbnet/SharePointSharedLinkDecoder</a></p>
<p>Now here&#8217;s how to get way more information:</p>
<ul>
<li>Using Graph Explorer: <a href="https://developer.microsoft.com/en-us/graph/graph-explorer" target="_blank" rel="noopener">https://developer.microsoft.com/en-us/graph/graph-explorer</a></li>
</ul>
<p>1. Ensure that you have the Files.ReadWrite.All permission</p>
<p><a href="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/permissionsGraph20032025.png?ssl=1"><img data-recalc-dims="1" loading="lazy" decoding="async" data-attachment-id="355558" data-permalink="https://www.pbnet.ro/?attachment_id=355558" data-orig-file="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/permissionsGraph20032025.png?fit=2546%2C1138&amp;ssl=1" data-orig-size="2546,1138" data-comments-opened="1" data-image-meta="{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}" data-image-title="permissionsGraph20032025" data-image-description="" data-image-caption="" data-large-file="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/permissionsGraph20032025.png?fit=678%2C303&amp;ssl=1" class="alignnone wp-image-355558" src="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/permissionsGraph20032025.png?resize=678%2C303&#038;ssl=1" alt="" width="678" height="303" srcset="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/permissionsGraph20032025.png?resize=1024%2C458&amp;ssl=1 1024w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/permissionsGraph20032025.png?resize=300%2C134&amp;ssl=1 300w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/permissionsGraph20032025.png?resize=768%2C343&amp;ssl=1 768w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/permissionsGraph20032025.png?resize=1536%2C687&amp;ssl=1 1536w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/permissionsGraph20032025.png?resize=2048%2C915&amp;ssl=1 2048w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/permissionsGraph20032025.png?w=1356&amp;ssl=1 1356w" sizes="auto, (max-width: 678px) 100vw, 678px" /></a></p>
<p>2. Encode your URL in Base64 using the following PowerShell script:</p><pre class="crayon-plain-tag">$sharingUrl = &quot;https://pbnet.sharepoint.com/:b:/s/BLABLA1/EXZD4nQEQEpLv2pPl-btZnkB3FrKUYbP7jXCEveeY_WfYA?e=hJCcWh&quot;
$base64Value = [Convert]::ToBase64String([System.Text.Encoding]::UTF8.GetBytes($sharingUrl))
$encodedUrl = &quot;u!&quot; + $base64Value.TrimEnd(&quot;=&quot;).Replace(&quot;/&quot;, &quot;_&quot;).Replace(&quot;+&quot;, &quot;-&quot;)
Write-Host $encodedUrl</pre><p>The result will be something like: u!aHR0cHM6Ly9wYm5ldC5zaGFyZXBvaW50LmNvbS86Yjovcy9CTEFCTEExL0VYWkQ0blFFUUVwTHYycFBsLWJ0Wm5rQjNGcktVWWJQN2pYQ0V2ZWVZX1dmWUE_ZT1oSkNjV2g</p>
<p>3. Go to Graph Explorer at: <a href="https://developer.microsoft.com/en-us/graph/graph-explorer" target="_blank" rel="noopener">https://developer.microsoft.com/en-us/graph/graph-explorer</a></p>
<p>The syntax of the URL should be like:</p>
<p>https://graph.microsoft.com/v1.0/shares/&lt;base64 shared link from PowerShell Script&gt;/driveItem?$expand=children</p>
<p>So the final URL is like: https://graph.microsoft.com/v1.0/shares/u!aHR0cHM6Ly9wYm5ldC5zaGFyZXBvaW50LmNvbS86Yjovcy9CTEFCTEExL0VYWkQ0blFFUUVwTHYycFBsLWJ0Wm5rQjNGcktVWWJQN2pYQ0V2ZWVZX1dmWUE_ZT1oSkNjV2g/driveItem?$expand=children</p>
<p>And there you go&#8230; you have the weburl, name of the file and name of the library:</p>
<p><a href="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/GraphInforesult2052025.png?ssl=1"><img data-recalc-dims="1" loading="lazy" decoding="async" data-attachment-id="355559" data-permalink="https://www.pbnet.ro/?attachment_id=355559" data-orig-file="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/GraphInforesult2052025.png?fit=1846%2C1195&amp;ssl=1" data-orig-size="1846,1195" data-comments-opened="1" data-image-meta="{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}" data-image-title="GraphInforesult2052025" data-image-description="" data-image-caption="" data-large-file="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/GraphInforesult2052025.png?fit=678%2C439&amp;ssl=1" class="alignnone size-large wp-image-355559" src="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/GraphInforesult2052025.png?resize=678%2C439&#038;ssl=1" alt="" width="678" height="439" srcset="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/GraphInforesult2052025.png?resize=1024%2C663&amp;ssl=1 1024w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/GraphInforesult2052025.png?resize=300%2C194&amp;ssl=1 300w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/GraphInforesult2052025.png?resize=768%2C497&amp;ssl=1 768w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/GraphInforesult2052025.png?resize=1536%2C994&amp;ssl=1 1536w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/GraphInforesult2052025.png?w=1846&amp;ssl=1 1846w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/GraphInforesult2052025.png?w=1356&amp;ssl=1 1356w" sizes="auto, (max-width: 678px) 100vw, 678px" /></a></p>
<ul>
<li>If you want to do this with Graph PowerShell and get the name of the file, the logic is similar to the script below:</li>
</ul>
<p></p><pre class="crayon-plain-tag">Import-Module Microsoft.Graph.Files
Connect-MgGraph -Scopes &quot;Files.ReadWrite.All&quot;


# Set the sharing URL
$sharingUrl = &quot;https://pbnet.sharepoint.com/:b:/s/BLABLA1/EXZD4nQEQEpLv2pPl-btZnkB3FrKUYbP7jXCEveeY_WfYA?e=hJCcWh&quot;
$base64Value = [Convert]::ToBase64String([System.Text.Encoding]::UTF8.GetBytes($sharingUrl))
$encodedUrl = &quot;u!&quot; + $base64Value.TrimEnd(&quot;=&quot;).Replace(&quot;/&quot;, &quot;_&quot;).Replace(&quot;+&quot;, &quot;-&quot;)

# Construct the Graph API request URL
$requestUrl = &quot;https://graph.microsoft.com/v1.0/shares/$encodedUrl/driveItem?$expand=children&quot;


$response=Get-MgShareDriveItem -SharedDriveItemId $encodedUrl -ExpandProperty &quot;children&quot;

# Output the file details
$response | Format-List</pre><p>The PowerShell output will be similar to:</p>
<p><a href="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/FIlenameGraphPS2032025.png?ssl=1"><img data-recalc-dims="1" loading="lazy" decoding="async" data-attachment-id="355563" data-permalink="https://www.pbnet.ro/?attachment_id=355563" data-orig-file="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/FIlenameGraphPS2032025.png?fit=1014%2C688&amp;ssl=1" data-orig-size="1014,688" data-comments-opened="1" data-image-meta="{&quot;aperture&quot;:&quot;0&quot;,&quot;credit&quot;:&quot;&quot;,&quot;camera&quot;:&quot;&quot;,&quot;caption&quot;:&quot;&quot;,&quot;created_timestamp&quot;:&quot;0&quot;,&quot;copyright&quot;:&quot;&quot;,&quot;focal_length&quot;:&quot;0&quot;,&quot;iso&quot;:&quot;0&quot;,&quot;shutter_speed&quot;:&quot;0&quot;,&quot;title&quot;:&quot;&quot;,&quot;orientation&quot;:&quot;0&quot;}" data-image-title="FIlenameGraphPS2032025" data-image-description="" data-image-caption="" data-large-file="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/FIlenameGraphPS2032025.png?fit=678%2C460&amp;ssl=1" class="alignnone size-full wp-image-355563" src="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/FIlenameGraphPS2032025.png?resize=678%2C460&#038;ssl=1" alt="" width="678" height="460" srcset="https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/FIlenameGraphPS2032025.png?w=1014&amp;ssl=1 1014w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/FIlenameGraphPS2032025.png?resize=300%2C204&amp;ssl=1 300w, https://i0.wp.com/www.pbnet.ro/wp-content/uploads/2025/03/FIlenameGraphPS2032025.png?resize=768%2C521&amp;ssl=1 768w" sizes="auto, (max-width: 678px) 100vw, 678px" /></a></p>
<p>Enjoy!</p>
<p>&nbsp;</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">355555</post-id>	</item>
		<item>
		<title>[SPO] Enable default sensitivity labels in SharePoint online</title>
		<link>https://www.pbnet.ro/?p=355258</link>
		
		<dc:creator><![CDATA[Andrei Rachita]]></dc:creator>
		<pubDate>Thu, 06 Mar 2025 08:24:43 +0000</pubDate>
				<category><![CDATA[Microsoft Technologies]]></category>
		<guid isPermaLink="false">https://www.pbnet.ro/?p=355258</guid>

					<description><![CDATA[So, here goes: [crayon-6a07556089187443150703/] Create and publish your label, then wait around 24h to have everything propagated. If you get any error with the following <a class="mh-excerpt-more" href="https://www.pbnet.ro/?p=355258" title="[SPO] Enable default sensitivity labels in SharePoint online">[...]</a>]]></description>
										<content:encoded><![CDATA[<p>So, here goes:</p><pre class="crayon-plain-tag"># Define the variables for your enviroment. The first one is the link to your SharePoint Admin Portal. The second one is your administrator account User Principal Name
 
$SPAdminLink = &quot;https://tenant-admin.sharepoint.com&quot;
$AdminUPN = &quot;user@domain.com&quot;
 
# Connect to SharePoint. Replace the link with your SharePoint Admin portal
# you need to have run install-module -name Microsoft.Online.SharePoint.PowerShell to have the module installed. 
 
Connect-SPOService -Url $SPAdminLink
 
# Enable AIP Integration
 
Set-SPOTenant -EnableAIPIntegration $true
(Get-SPOTenant).EnableAIPIntegration
 
# Enable support for PDFs. Update SP Online Module if this fails. The link is https://www.microsoft.com/en-us/download/details.aspx?id=35588
 
Set-SPOTenant -EnableSensitivityLabelforPDF $true
(Get-SPOTenant).EnableSensitivityLabelforPDF
 
# Connect to AAD and enable support for labels in groups. Source: https://learn.microsoft.com/en-us/microsoft-365/compliance/sensitivity-labels-teams-groups-sites?view=o365-worldwide
 
Install-Module AzureADPreview
AzureADPreview\Connect-AzureAD
 
$grpUnifiedSetting = (Get-AzureADDirectorySetting | where -Property DisplayName -Value &quot;Group.Unified&quot; -EQ)
$Setting = $grpUnifiedSetting
 
# Check if EnableMIPLabels is enabled. If nothing is displayed then you have no group settings. We'll enable it. 
 
$grpUnifiedSetting.Values
 
# Enable the feature. If it fails check out this guide: https://learn.microsoft.com/en-us/azure/active-directory/enterprise-users/groups-settings-cmdlets#create-settings-at-the-directory-level
 
$Setting[&quot;EnableMIPLabels&quot;] = &quot;True&quot;
 
# Check that now it's enabled. If it's enabled you'll get
#
#Name                            Value
#----                            -----
#EnableMIPLabels                 True
 
$Setting.Values                                                                                                                                                                                                    
 
# Save 
 
Set-AzureADDirectorySetting -Id $grpUnifiedSetting.Id -DirectorySetting $Setting
 
# Now we'll import ExchangeOnlineManagement and then connect the Compliance Powershell to sync the labels
 
#You might have problems running the below part in PowerShell ISE. If you do, run them in a normal PowerShell session
#Also, ensure you have the module installed with Install-Module -Name ExchangeOnlineManagement
Import-Module ExchangeOnlineManagement
Connect-IPPSSession -UserPrincipalName $AdminUPN
Execute-AzureAdLabelSync</pre><p>Create and publish your label, then wait around 24h to have everything propagated.</p>
<p>If you get any error with the following cmdlet: $grpUnifiedSetting = (Get-AzureADDirectorySetting | where -Property DisplayName -Value &#8220;Group.Unified&#8221; -EQ) follow the steps in this article: <a href="https://learn.microsoft.com/en-us/entra/identity/users/groups-settings-cmdlets">Configure group settings using PowerShell &#8211; Microsoft Entra ID | Microsoft Learn</a></p>
<p>Hint:</p>
<p>Connect-MgGraph -TenantId 0f2434f0-d209-4e5f-9536-2bfb2dd9c2b7 -Scopes Directory.ReadWrite.All</p>
<p><em>You can get the tenantID from Entra</em></p>
<p>&nbsp;</p>
<p>Enjoy!</p>
<p>&nbsp;</p>
]]></content:encoded>
					
		
		
		<post-id xmlns="com-wordpress:feed-additions:1">355258</post-id>	</item>
	</channel>
</rss>
