반응형

In this post, we will walk through how to configure a Shared PC (Shared Device) using Microsoft Intune.

Shared PCs are commonly used in environments such as:

  • Meeting rooms
  • Training centers
  • Lobby kiosks
  • Factory floor terminals

 

Because multiple users access the same device, credential management and data persistence prevention are critical.

For example:

  • User A finishes work but forgets to sign out.
  • User B logs in next and unintentionally gains access to User A’s session or data.

This scenario can create serious risks from a privacy and compliance perspective.

To mitigate this risk, Intune provides the Shared multi-user device policy, which allows you to automatically delete user profiles when users sign out.

Official documentation:
Shared or multi-user Windows device settings in Microsoft Intune - Microsoft Intune | Microsoft Learn


Step 1. Enroll the Device into Intune

Before deploying policies, the device must first be enrolled in Intune.

 

 

Even if the device is intended for shared usage, enrollment should be performed using an administrator or master account.

After enrollment:

  1. Create a Security Group for policy deployment
  2. Add the shared PC to the group

 

Only after completing these steps can the policy be successfully assigned.


Step 2. Create a Shared Multi-User Device Policy

Navigation Path

Intune Admin Center > Devices > Windows > Manage Devices > Configuration > Create > New Policy

Select the following options:

  • Platform: Windows 10 and later
  • Profile Type: Templates
  • Template: Shared multi-user device

 

Then assign a policy name.


Policy Configuration Example

 

Below is an example configuration:

Policy Setting Value Description Meaning
Shared PC mode Enable Enables shared multi-user mode Activates account cleanup and shared operations
Guest account Guest and Domain Allows Guest and Entra ID sign-in Supports M365 and Guest login
Account management Enabled Enables automatic account management Automatically manages user profiles
Account Deletion Immediately after log-out Deletes profile upon sign-out Immediately removes user traces
Local Storage Disabled Controls local storage usage Prevents persistent local data
Power Policies Enabled Applies power settings Enables power management control
Sleep timeout 300 seconds Idle time before sleep Enters sleep after 5 minutes
Sign-in when PC wakes Enabled Requires login after wake Protects active sessions
Maintenance start time Not set Maintenance window Uses default behavior
Education policies Not configured Education-specific settings No impact in enterprise environments

Key Design Intent of This Configuration

1️⃣ Immediate Profile Deletion Upon Sign-out

When a user signs out, their profile is immediately deleted.

→ Prevents residual data from remaining on the shared device.

Note: The contents of the Downloads folder are also removed after sign-out.


2️⃣ Local Storage Restriction

By disabling local storage, files are not permanently stored on the shared device.


3️⃣ Sign-in Required After Sleep

  • Device enters sleep after inactivity
  • User must sign in again when waking the device

→ Prevents session hijacking


4️⃣ When Entra ID Sign-in Is Allowed

If users sign in with their M365 (Entra ID) account:

  • OneDrive integration is available
  • Personal environment is maintained during the session
  • Profile is deleted after sign-out

This enables temporary personalization while maintaining shared-device security.


Assigning the Policy

Assign the policy to the device group and create it.

 

Once applied:

  • Users can sign in using Guest or Domain accounts

  • A new profile is created each time a user signs in

  • Only the Downloads folder is accessible in File Explorer

  • Data inside Downloads is removed after sign-out

Considerations When Using Guest Accounts

Guest accounts do not require a password by default.

If a user leaves without signing out:

  • The next user may access the active session
  • Previous user activity may be visible

This can create a security vulnerability.


Advantages of Allowing Entra ID Sign-in

When Domain (Entra ID) sign-in is enabled:

  • Re-authentication is required after screen lock
  • Session protection is enhanced
  • Overall security posture improves

Depending on the enterprise environment, Entra ID-based sign-in is generally recommended.


Additional Mitigation for Guest-Based Environments

If operating primarily with Guest accounts, consider implementing:

  • Automatic forced sign-out after a defined idle time
  • Screen lock enforcement
  • Additional session protection policies

This can be achieved through PowerShell scripts or Intune remediation scripts.

반응형
반응형

Many IT engineers and managers are unaware that if your Hyper-V host server is running Windows Server Datacenter Edition, you can use AVMA (Automatic Virtual Machine Activation) keys to automatically activate guest VMs. Leveraging this feature simplifies the activation process and makes management much easier.

In this post, I’ll walk you through how AVMA works, how to use it, and some practical tips for automating Windows Server VM activation on Hyper-V.

 

Youtube: https://youtu.be/deyWNdW6S-U

 


What is AVMA?

AVMA (Automatic Virtual Machine Activation) allows you to activate Windows Server virtual machines running on a Datacenter edition Hyper-V host without needing to enter a product key for each VM. This is especially useful for environments where you frequently deploy or redeploy VMs.

Reference:
Automatic Virtual Machine Activation in Windows Server | Microsoft Learn

  • Guest VM: The version of Windows Server you can activate depends on the host OS version.

Supported Host and Guest Combinations

For example, if your host is Windows Server 2025, you can activate guest VMs from 2012 R2 up to 2025 using AVMA keys.


AVMA Keys for Each Windows Server Version

You can find the official AVMA keys in Microsoft’s documentation. Here are some examples:


How to Use AVMA Keys During Installation

When installing Windows Server as a VM on your Hyper-V Datacenter host, you can enter the AVMA key during setup:

Choose a licensing method:
Select “Use a product key” and enter the AVMA key for your OS version.

Select the image:
The installer will recognize the OS version that matches the AVMA key.


Post-Installation Activation

After installation, you might notice that Windows is not yet activated. Here’s how to proceed:

Check Activation Status:
Go to Start > Settings > System > Activation. If not activated, you may see an error (e.g., 0xC004F012).

 

Activate via Command Line:
Open PowerShell or Command Prompt as Administrator and run:

 

This will trigger activation using the AVMA key.

 

Verify Activation:
The activation state should now show as “Active”.


Activating an Already Installed VM

If you’ve already installed the OS without entering a key, you can still activate:

 

Go to System Settings:
Start > System > About > Product key and activation.

 

 

Change Product Key:
Enter the appropriate AVMA key and proceed with activation.

 

Next

 

Activate


Pro Tip: Using Sysprep

After completing activation, running Sysprep is highly recommended for managing test environments efficiently. This avoids repetitive product key entry and ensures your template VMs are ready for rapid deployment.


Conclusion

AVMA is a powerful feature for anyone managing Windows Server VMs on Hyper-V Datacenter hosts. It streamlines activation, reduces manual work, and helps maintain compliance. Make sure to use the correct AVMA key for your guest OS version, and enjoy hassle-free VM deployments!


 

반응형
반응형

Previously, I covered how to export a Power BI M Query from Microsoft Sentinel and connect it to Power BI Desktop.

2025.08.24 - [Microsoft 365] - Microsoft 365 Log Management (2): Connecting MDI Logs to Sentinel and Power BI

 

While doing a self-study to compare Endpoint DLP logs against Microsoft Defender for Endpoint (MDE) logs, I ran into a practical issue: in Power BI, reorganizing column order can be surprisingly annoying when you just want to quickly compare a few fields side by side.

 

After digging in, I found a very handy trick:

✅ You can take the M Query exported from Sentinel/Log Analytics and paste it directly into Excel Power Query—and it works.

 

If you do analysis primarily in Excel (filters, quick comparisons, pivot tables), this approach is super practical.

So here’s the clean workflow:

“M Query export → Excel connection → analysis”

 

Youtube: https://youtu.be/iuyK1sINfzw

 


TL;DR

  • In Sentinel / Log Analytics, export your query using Export to Power BI (as an M query).
  • In Excel, open Power Query (Blank Query) and paste the M Query into the Advanced Editor.
  • Authenticate using Organizational account, then Close & Load to load it into a worksheet table.
  • From then on, just hit Refresh to update logs—no more re-running the same query in the portal.

Step 1) Export the M Query from Sentinel / Log Analytics

In the Azure Portal, navigate to either:

  • Microsoft Sentinel > Logs

  • Log Analytics Workspace > Logs

 

 

Write or select the query for the table > Setting Time range > Share > Export to Power BI (as an M query)


Step 2) Connect to Log Analytics Using M Query in Excel

2-1) Create a Blank Query

In Excel:

  • Data > Get Data > From Other Sources > Blank Query


2-2) Paste the M Query into Advanced Editor

In the Power Query Editor:

Open Advanced Editor

 

 

Paste the entire M Query you downloaded in Step 1 as-is

A typical exported M Query includes things like:

  • The target table
  • The query time range

 

✅ Pro tip: If you need to connect multiple tables, just duplicate the query and update only the table name and time span section. It’s the fastest way to scale your workbook.


2-3) Configure Credentials (Authentication)

On first connection, you may see Edit Credentials.

 

 

Organizational account → sign in → Connect


2-4) Load to Excel and Refresh Anytime

Before loading:

  • Rename the query to something meaningful
  • Then choose Close & Load to load into an Excel worksheet table

  • Use filters, sorting, pivots, conditional formatting, side-by-side comparisons… all the Excel stuff that’s great for fast investigation.

 

And the best part:

Refresh updates the dataset without re-running the whole process in the portal.


Step 3) Bonus: Analyze Logs with Copilot (Excel + OneDrive/SharePoint)

After loading logs into Excel:

  1. Save the workbook to OneDrive or SharePoint
  2. Ask Copilot to analyze the data

If Copilot recognizes your tables (for example, MDE-related tables), it can quickly do things like:

  • Summaries
  • Trend analysis
  • Outlier/anomaly detection
  • Quick insights and narrative explanations

Wrap-up

Using M Query Export from Sentinel/Log Analytics isn’t just for Power BI—you can connect it directly to Excel and build a refreshable log analysis workbook.

If your workflow is centered on:

  • Fast comparison
  • Column reordering
  • Filtering
  • Pivot-based analysis

…then Excel can be the more efficient tool. And once the dataset is in OneDrive/SharePoint, Copilot becomes an extra boost for rapid investigation.

반응형

+ Recent posts