Abe windows server 2016

По умолчанию, когда пользователь открывает некую общую сетевую папку на сервере (предполагаем, что у пользователя есть право на доступ к сетевой шаре), SMB отображает ему полный список каталогов и файлов, которые находятся в ней. Функционал Windows «перечисление на основе доступа» (Access Based EnumerationABE) позволяет в сетевой папке скрыть от пользователя те файлы и папки, на которые у него отсутствуют NTFS разрешения.

Технология Access Based Enumeration впервые появилась еще в Windows Server 2003 SP1 и помогает предотвратить просмотр пользователями списков чужих файлов и папок.

Процесс доступа к сетевой папке в среде Windows выполняется следующим образом:

  1. Пользователь обращается к серверу и запрашивает доступ к общей сетевой папке
  2. Служба LanmanServer на сервере (именно она отвечает за предоставление доступа к файлам по SMB) проверяет, есть ли у пользователя необходимые разрешений на доступ к данной сетевой папке. Если доступ имеется, служба возвращает список пользователю список с содержимым папки
  3. Затем пользователь может выбрать и попытаться открыть необходимый ему файл или папку
  4. Сервер проверяет, имеет ли пользователь необходимые NTFS права на доступ к данному элементу. Если у пользователя есть необходимые разрешения, он открывает нужный объект. Если у пользователя не достаточно прав — возвращается ошибка отказа в доступе.

Согласно этому алгоритму сервер сначала возвращает пользователю список всего содержимого папки, а проверка наличия прав доступа к отдельным файлам и папкам выполняется только при обращении к ним. При включении ABE, служба LanmanServer вернет пользователю не все содержимое папки, а только те объекты файловой системы, на которые у пользователя есть права (Read или List contents).

Некоторые особенности ABE:

  • ABE управляет только списком содержимого общей папки, но не скрывает сами шары от пользователей. Поэтому, когда пользователь подключается к серверу (\\server-name), он увидит все имеющиеся на нем шары. Чтобы создать скрытую шару, нужно добавить в конец ее имени знак $, например SecretFolder$
  • При локальном или RDP входе пользователя на сервер, ABE не работает
  • Члены локальной группы «Администраторы» всегда видят полное содержимое сетевой папки

ABE включается для каждой сетевой папки по отдельности. Чтобы настроить ABE, откройте консоль Server Manager и выберите роль «File and Storage Services» (роль уже должна быть установлена).

 консоль Server Manager

Затем перейдите в раздел «Shares» и выберите из списка сетевую папку, для которой необходимо включить ABE. Щелкните правой кнопкой по папке и выберите «Properties».

свойства сетевого каталога

В окне свойств папки перейдите на вкладку Settings и включите опцию Enable access-based enumeration.

включить access based enumeration

Кроме того, вы можете включить перечисление на основе доступа на сетевом ресурсе с помощью PowerShell командлета Set-SmbShare:

Set-SmbShare -Name "Share" -FolderEnumerationMode AccessBased

Set-SmbShare

В том случае, если вы управляете общими папками централизованно с помощью GPO (секция Computer Configuration -> Preferences -> Windows Settings -> Network Shares), вы можете включить ABE в ее свойствах (скрин ниже).

Computer Configuration - data-lazy-src=

В качестве небольшой иллюстрации работы ABE. На скриншоте ниже показано как выглядит содержимое сетевой папки, для которой включен ABE для системного администратора сервера.

содержимое сетевой папки

А так в проводнике выглядит та же самая папка для менеджера из отдела управления активами.

Как работает перечисление на основе доступа для сетевой папки файлового сервера

Таким образом, технология ABE облегчает жизнь как пользователям, так и администраторам. Пользователи не видят лишнюю и избыточную информацию в проводнике, а администратору не нужно больше отвечать на вопросы пользователи об отсутствии доступа к той или иной папке.

Однако у технологии Access Based Enumeration есть и небольшой недостаток — дополнительная нагрузка на сервер. Нагрузка зависит от количества пользователей сервера, количества объектов в общих папках и сложности ACL. При высокой загрузке сервера, скорость открытия папок на файловом сервере может значительно снижаться.

Access-based Enumeration (ABE) allows objects (files, folders) on local resources to be hidden from users who do not have permission for those objects. Access-based Enumeration was designed to cut the grapevine before it can even grow.

Here at Ibmi Media, as part of our Server Management Services, we regularly help our Customers to perform related Windows servers queries.

Enable ABE on Windows Server

Here, let us see how to configure and use of ABE in various Windows versions.

How does access to shared folders work in Windows ?

By enabling ABE on a shared folder, we can ensure that different users see a different list of folders and files in the same network share based on the user’s individual access permissions (ACL).

Let us see how the interaction between the client and the server occurs when accessing a shared folder over the SMB:

  • Firstly, a client requests the server to access a directory in the network shared folder.
  • Then, the LanmanServer service on the server checks the user permissions to access this folder.
  • Next, if access is allowed (NTFS permissions: list content, read or write), the user sees the directory contents.
  • Then, the user requests access to a file or a subfolder in the same way (we can view who opened a specific file in a network folder like this).
  • Finally, if the access is denied, the user is notified accordingly.

According to this scheme, the server firstly shows the entire contents of the folder to the user.

Then, when the user tries to open a specific file or folder the NTFS permissions are checked.

If we need to hide a shared folder from a user, we have to add a $ symbol at the end of the share name.

We can manage ABE from the command prompt (abecmd.exe utility), from the GUI, PowerShell or a special API.

Access-Based Enumeration Restrictions

Access-based Enumeration on Windows does not work in the following cases:

  • If we are using Windows XP or Windows Server 2003 without Service Pack 1 as a file server.
  • Then, if we are viewing directories locally (directly from the server) or connecting via RDP.
  • For members of the local file server administrators group (they always see the full list of files).

How to use ABE on Windows Server 2008/2008 R2 ?

To enable Access-based Enumeration for a certain folder in Windows Server 2008/2008 R2, follow the steps given below:

  • Open the MMC management console Share and Storage Management (Start –> Programs –> Administrative Tools -> Share and Storage Management).
  • Go to the properties of the necessary share.
  • Then go to the Advanced settings and check Enable access-based enumeration.

How to Configure Access-based Enumeration on Windows Server 2012 R2/2016 ?

To enable ABE in Windows Server 2012, follow the steps given below:

  • Firstly, we have to install File and Storage Services role.
  • Then go to the share properties in the Server Manager.
  • In Settings section, check the option Enable access-based enumeration.

How to Implement Access-Based Enumeration on Windows Server 2003 ?

In Windows Server 2003 (not supported now), ABE became supported starting from Service Pack 1.

To enable Access-based Enumeration in Windows Server 2003 SP1 (or later), follow the steps given below:

1. Firstly, download and install a package following this link:

https://www.microsoft.com/en-us/download/details.aspx?id=15656

2. Then during installation, we have to specify whether ABE will be enabled for all shared folders on the server or we will configure it manually. If we choose the second option, a new tab, Access-based Enumeration, will appear in the network share properties after the installation.

3. Finally, to activate ABE for a certain folder, check the option «Enable access-based enumeration on this shared folder» in its properties.

How to Manage ABE from the Command Prompt ?

We can manage Access-based Enumeration settings from the command prompt using Abecmd.exe utility.

This tool is a part of Access-based Enumeration package for Windows Server 2003 SP1.

Abecmd.exe allows to activate ABE for all directories at once or only for some of them. The next command enables Access-Based Enumeration for all shares:

abecmd /enable /all

This one is for a certain folder (for example, a network shared folder with the name Docs):

abecmd /enable Docs

How to Manage Access Based Enumeration Using PowerShell ?

We can use the SMBShare PowerShell module (installed by default in Windows 10/8.1 and Windows Server 2016/2012 R2) to manage the settings of Access Based Enumeration for specific folders.

To list the properties of a specific shared folder:

Get-SmbShare Install|fl

Note the value of the FolderEnumerationMode attribute. In our case, its value is Unrestricted. This means that ABE is disabled for this folder.

Then, we can check the status of ABE for all shared folders of the server:

Get-SmbShare | Select-Object Name,FolderEnumerationMode

To enable ABE for a specific folder:

Get-SmbShare Install | Set-SmbShare -FolderEnumerationMode AccessBased

We can enable Access Based Enumeration for all published network folders (including administrative shares ADMIN$, C$, E$, IPC$,…) by running the command:

Get-SmbShare | Set-SmbShare -FolderEnumerationMode AccessBased

To disable ABE use the command:

Get-SmbShare Install | Set-SmbShare -FolderEnumerationMode Unrestricted

Access-Based Enumeration in Windows 10/8.1/7

In Windows 10 (Server 2016) and Windows 8.1 (Server 2012R2), we can use PowerShell to manage Access-based Enumeration.

In older versions of Windows, we need to install the latest version of PowerShell (>= 5.0) or use the abecmd.exe utility from the Windows Server 2003 package, it works fine on client OSs.

Since the Windows Server 2003 Access-based Enumeration package is not installed on Windows 10, 8.1 or 7, we have to install it first on Windows Server 2003 and then copy it from the C:\windows\system32 directory to the same folder on the client. After that, we can enable ABE.

We can enable ABE in DFS using DFS Management or dfsutil.exe:

dfsutil property abde enable \\namespace_root

In addition, we can enable ABE on computers in the AD domain using GPO. This can be done using GPP in the section:

Computer Configuration -> Preferences -> Windows Settings -> Network Shares

In the properties of the network folder there is an Access-Based Enumeration option, if we change the value to Enable, ABE mode will be enabled for all shared folders created using this GPO.

[Need assistance in fixing Windows Server errors? We can help you. ]

Access-Based Enumeration (ABE, перечисление на основе доступа) это опция файлового сервера Windows, которая позволяет скрыть от пользователя файлы и папки, к которым у него доступа. Это позволяет скрыть структуру каталогов и имена папок и файлов в общей сетевой папке.

Содержание:

  • Как включить Access Based Enumeration в Windows Server
  • Управление Access Based Enumeration из командной строки (PowerShell)

Как включить Access Based Enumeration в Windows Server

Рассмотрим сценарий, когда на файловом сервере Windows есть некая общая сетевая папка с каталогами нескольких отделов. Все пользователи могут просматривать список директорий в этой папке (для этого на корневую папку даны права List folder или Traverse folder для группы Users). Но пользователи могут зайти только в каталоги, в списки доступа NTFS которых они добавлены.

Предположим, пользователь добавлен в группы доступа AD, назначенные на 2 каталога Public и Salary.

Группы безопасности AD добавлены в NTFS разрешения соответствующих подкаталогов в общей папки. Из ACL убраны разрешения, дающие доступ к подпапкам для групп Domain Users или Builtin\Users.

Чтобы включить ABE, откройте консоль Server Manager -> выберите роль File and Storage Services -> Shares. Отройте свойства общей папки и на вкладке Settings включите опцию Enable access-based enumeration.

Включить access based enumeration для сетевой папки на windows server через manager

Обновите содержимое общей папки у пользователя. Теперь пользователеь видит только два каталога, к которым ему предоставлен доступ. Оставшиеся папки скрыты от пользователя.

скрыть папки от пользователя через access based enumeration

Кроме того, вы можете включать ABE на компьютерах домена AD с помощью групповых политик. Для этого используется GPP в секции: Computer Configuration -> Preferences -> Windows Settings -> Network Shares).

Включить Access-Based Enumeration с помощью групповых политик

Если включить опцию Access-Based Enumeration, то для сетевой папки, опубликованной с помощью данной GPO, будет включен режим ABE.

Управление Access Based Enumeration из командной строки (PowerShell)

Можно включить ABE для сетевой папки из командной строки PowerShell.

Это в том числе позволяет включить Access-Based enumeration для сетевых папок, опубликованных на обычных рабочих станциях с десктопными версиями Windows 10 и 11.

Например, чтобы включить режим перечисления для общей папка с именем Docs, выполните команду:

Get-SmbShare Docs | Set-SmbShare -FolderEnumerationMode AccessBased

Вывести список опубликованных сетевых папок (включая общие административные папки Windows) и статус опции ABE:

Get-SmbShare | Select-Object Name,FolderEnumerationMode

Значение FolderEnumerationMode =
AccessBased
указывает, что Access Based-enumeration для них включен.

PowerShell включить FolderEnumerationMode AccessBased для сетевой папки

Отключить ABE для папки:

Get-SmbShare Docs | Set-SmbShare -FolderEnumerationMode Unrestricted

В Samba сервере на Linux для включения Access-based Enumeration нужно добавить в конфигурационный файл
smb.conf
опции:

hide unreadable = Yes
access based share enum = Yes

В корпоративной среде ABE часто применяется для папок DFS, скрывая от пользователей «ненужные» папки и предоставляя более удобную структуру дерева общих папок. Включить ABE на пространстве имен DFS можно с помощью консоли DFS Management или утилиты dfsutil.exe:
dfsutil property abde enable \\<namespace root>

Другие особенности и ограничений Access-based Enumeration в Windows

  • Включение ABE на файловых серверах может увеличить нагрузку на сервер. Особенно заметна будет задержка отображения списка файлов в каталогах, которые содержат тысячи файлов (например, при наличии 15000 объектов в общей папке, скорость ее открытия замедлится на 1-3 секунды).
  • ABE не работает при локальном просмотре каталогов на сервере.
  • Члены локальной группы администраторов файлового сервера всегда видят полный список объектов в сетевой папке.

Cyber Security

Access based enumeration enables you to configure advanced display options for shared folders. If a user is mapped to a network drive and this network drive has the Access Based Enumeration Feature enabled then this user can only see folders that he has access to. So far so good. Now I’m going to show how to configure this great feature in the graphical interface and – of course – in Windows PowerShell.

But let me first say some things about this feature. The question is why would you want to do this?

A defense of Access Based Enumeration 😉

Security

The first reason is security. Why do you want to show files and folders to users that have no access to it? No need for.

User Experience

The second reason is user experience. Why do you want to distract user with tons of files and folders that they don’t have access to? Remember: If your users are fine, then you are fine.

Configuring Access Based Enumeration with Server Manager

On the server which holds the shared folder open Server Manager. Click on File and Storage Services.

1.PNG

Next click on Shares.

2.PNG

Select your shared folder and right click it. Select Properties. Activate the checkbox Access Based Enumeration.

4.PNG

Configuring Access Based Enumeration by using Windows PowerShell

Welcome to the Champions League! Who needs Server Manager? 😉

Set-SmbShare -Name Data -FolderEnumerationMode AccessBased

1.PNG

To verify your settings run

Get-SmbShare -Name Data | Select-Object FolderEnumerationMode

1.PNG

To check all your local shares run

Get-SmbShare | Select-Object Name,FolderEnumerationMode

1.PNG

The Impact

Ok, if this is the first time you’ve heard from this great feature, then you might think “Hmm… does this really works in my environment?” Ok, Ok I will give you preview. So, let’s have a look to the permissions of user Petra. Petra has access to the shared folder Data and to it’s subfolders HR and PR, but not IT.

On the left side you see the server’s view and on the right side Petra’s view. Quite different … Petra does not have access to the IT folder. Therefore she can see only the folders HR and PR.

Have fun with Access Based Enumeration and don’t forget: If your users are fine, then you are fine. 😉

See also

More about File Shares in my blog posts

PowerShell: Find and close open files (SMB Share)

PowerShell: How to create File Shares

Published by Patrick Gruenauer

Microsoft MVP on PowerShell [2018-2025], IT-Trainer, IT-Consultant, MCSE: Cloud Platform and Infrastructure, Cisco Certified Academy Instructor.
View all posts by Patrick Gruenauer

Access-based Enumeration (ABE) is a shared folder option in Windows that allows to hide files and folders that users don’t have permission to access. ABE is used to hide the directory structure and the names of folders and files, and to limit the number of items in a particular user folder view for a shared network folder.

Contents:

  • Using Access-based Enumeration on Windows Server
  • Managing Access-based Enumeration from the Command Prompt (PowerShell)

Using Access-based Enumeration on Windows Server

Let’s say there is a shared network folder on a Windows file server containing the public directories of several departments. All users can see the list of directories in this share. This is done by assigning the List Folders or Browse Folders permissions for the built-in Users group to the root of the folder only. The user will only be able to open the subdirectory if their account is added to the NTFS access list.

implementing abe on windows shared folder

Let’s assume that a user is added to the AD security groups that allow two sub-directories to be opened (Public and Salary).

These AD security groups are added to the NTFS permissions of the corresponding sub-directories in a share. Permissions that grant access to sub-folders for the Domain Users group or the Builtin\Users group have been removed from the ACLs.

To enable ABE on a shared folder, open the Server Manager console -> select the File and Storage Services role -> Shares. Open the share properties and enable the Enable access-based enumeration option on the Settings tab.

Server Manager: enable access based enumeration for a shared folder

Refresh shared folder contents in a user session (press F5 in the File Explorer). Now the user sees only two directories that he can access. The rest of the sub-folders are not visible to the user.

In addition, you can enable ABE on computers in the AD domain using Group Policies. This can be done using the GPP option under Computer Configuration -> Preferences -> Windows Settings -> Network Shares.

enable abe using gpo

Enabling Access-based Enumeration will enable ABE mode for the shared folder published by this GPO.

Managing Access-based Enumeration from the Command Prompt (PowerShell)

You can also enable ABE for a shared network folder from the PowerShell command prompt.

This allows enabling Access-based Enumeration for shared folders on workstations running desktop OS versions (Windows 10 or 11).

For example, to enable access base enumeration mode for a shared folder named DOCS, run the command:

Get-SmbShare DOCS | Set-SmbShare -FolderEnumerationMode AccessBased

List all shared folders (including Windows administrative shares) and the status of the ABE option:

Get-SmbShare | Select-Object Name,FolderEnumerationMode

The value FolderEnumerationMode = AccessBased indicates that access-based enumeration is enabled.

powershell: enable access-based enum on share

Disable ABE for a share:

Get-SmbShare DOCS | Set-SmbShare -FolderEnumerationMode Unrestricted

To enable Access-based enumeration on a Linux Samba server, add the following options to the smb.conf configuration file

hide unreadable = Yes

The shared folders themselves, to which the user doesn’t have access permissions, can be hidden from the network environment using another Samba option.

access based share enum = Yes

In a corporate environment, ABE works perfectly with DFS folders by hiding unused folders from users and providing a more convenient public folder tree structure.  You can enable ABE in DFS using the DFS Management snap-in or dfsutil.exe command:
dfsutil property abde enable \\namespace_root

Other features and limitations of Access-based enumeration on Windows

  • Enabling ABE on a file server may increase the load on the host. There may be a slight delay when refreshing a list of files in an ABE-enabled folder containing thousands of items. For example, folder access will slow down by 1-3 seconds if there are 15,000 objects in a shared folder.
  • When browsing a directory locally on the file server, ABE is not used.
  • Members of the local Administrators group on the file server will always see a full list of the items in a shared folder.

Понравилась статья? Поделить с друзьями:
0 0 голоса
Рейтинг статьи
Подписаться
Уведомить о
guest

0 комментариев
Старые
Новые Популярные
Межтекстовые Отзывы
Посмотреть все комментарии
  • Устаревшая вызывающая сторона ядра windows 10
  • Живые обои для windows 10 iron man
  • Hevc to mp4 windows
  • Igfxem exe что это за процесс windows 10
  • Htc windows phone htc mozart