forked from PowerShell/PowerShell
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathNetShareEnum.cs
More file actions
26 lines (22 loc) · 741 Bytes
/
Copy pathNetShareEnum.cs
File metadata and controls
26 lines (22 loc) · 741 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
// Copyright (c) Microsoft Corporation.
// Licensed under the MIT License.
#nullable enable
using System.Runtime.InteropServices;
internal static partial class Interop
{
internal static unsafe partial class Windows
{
internal const int MAX_PREFERRED_LENGTH = -1;
internal const int STYPE_DISKTREE = 0;
internal const int STYPE_MASK = 0x000000FF;
[LibraryImport("Netapi32.dll", StringMarshalling = StringMarshalling.Utf16)]
internal static partial int NetShareEnum(
string serverName,
int level,
out nint bufptr,
int prefMaxLen,
out uint entriesRead,
out uint totalEntries,
ref uint resumeHandle);
}
}