Skip to content

Commit 9208af3

Browse files
authored
Merge pull request #892 from corob-msft/cr-issue282
Clarify use of /DYNAMICBASE and /HIGHENTROPYVA for 282
2 parents dc5d0bb + abf12a6 commit 9208af3

4 files changed

Lines changed: 101 additions & 102 deletions

File tree

Lines changed: 32 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "-DYNAMICBASE (Use address space layout randomization) | Microsoft Docs"
33
ms.custom: ""
4-
ms.date: "11/04/2016"
4+
ms.date: "06/12/2018"
55
ms.technology: ["cpp-tools"]
66
ms.topic: "reference"
77
f1_keywords: ["VC.Project.VCLinkerTool.RandomizedBaseAddress"]
@@ -13,37 +13,34 @@ ms.author: "corob"
1313
ms.workload: ["cplusplus"]
1414
---
1515
# /DYNAMICBASE (Use address space layout randomization)
16-
Specifies whether to generate an executable image that can be randomly rebased at load time by using the address space layout randomization (ASLR) feature of [!INCLUDE[windowsver](../../build/reference/includes/windowsver_md.md)].
17-
18-
## Syntax
19-
20-
```
21-
/DYNAMICBASE[:NO]
22-
```
23-
24-
## Remarks
25-
By default, /DYNAMICBASE is on.
26-
27-
This option modifies the header of an executable to indicate whether the application should be randomly rebased at load time.
28-
29-
Address space layout randomization is supported on [!INCLUDE[windowsver](../../build/reference/includes/windowsver_md.md)].
30-
31-
### To set this linker option in Visual Studio
32-
33-
1. Open the project **Property Pages** dialog box. For more information, see [Working with Project Properties](../../ide/working-with-project-properties.md).
34-
35-
2. Expand the **Configuration Properties** node.
36-
37-
3. Expand the **Linker** node.
38-
39-
4. Select the **Advanced** property page.
40-
41-
5. Modify the **Randomized Base Address** property.
42-
43-
### To set this linker option programmatically
44-
45-
1. See <xref:Microsoft.VisualStudio.VCProjectEngine.VCLinkerTool.RandomizedBaseAddress%2A>.
46-
47-
## See Also
48-
[Setting Linker Options](../../build/reference/setting-linker-options.md)
49-
[Linker Options](../../build/reference/linker-options.md)
16+
17+
Specifies whether to generate an executable image that can be randomly rebased at load time by using the address space layout randomization (ASLR) feature of Windows that was first available in Windows Vista.
18+
19+
## Syntax
20+
21+
> **/DYNAMICBASE**[**:NO**]
22+
23+
## Remarks
24+
25+
The **/DYNAMICBASE** option modifies the header of an *executable image*, a .dll or .exe file, to indicate whether the application should be randomly rebased at load time, and enables virtual address allocation randomization, which affects the virtual memory location of heaps, stacks, and other operating system allocations. The **/DYNAMICBASE** option applies to both 32-bit and 64-bit images. ASLR is supported on Windows Vista and later operating systems. The option is ignored by earlier operating systems.
26+
27+
By default, **/DYNAMICBASE** is enabled. To disable this option, use **/DYNAMICBASE:NO**. The **/DYNAMICBASE** option is required for the [/HIGHENTROPYVA](highentropyva-support-64-bit-aslr.md) option to have an effect.
28+
29+
### To set this linker option in Visual Studio
30+
31+
1. Open the project **Property Pages** dialog box. For more information, see [Working with Project Properties](../../ide/working-with-project-properties.md).
32+
33+
1. Select the **Configuration Properties** > **Linker** > **Advanced** property page.
34+
35+
1. Modify the **Randomized Base Address** property.
36+
37+
### To set this linker option programmatically
38+
39+
- See <xref:Microsoft.VisualStudio.VCProjectEngine.VCLinkerTool.RandomizedBaseAddress%2A>.
40+
41+
## See also
42+
43+
- [Setting Linker Options](../../build/reference/setting-linker-options.md)
44+
- [Linker Options](../../build/reference/linker-options.md)
45+
- [/HIGHENTROPYVA](highentropyva-support-64-bit-aslr.md)
46+
- [Windows ISV Software Security Defenses](http://msdn.microsoft.com/library/bb430720.aspx)
Lines changed: 18 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "-DYNAMICBASE | Microsoft Docs"
33
ms.custom: ""
4-
ms.date: "11/04/2016"
4+
ms.date: "06/12/2018"
55
ms.technology: ["cpp-tools"]
66
ms.topic: "reference"
77
f1_keywords: ["/dynamicbase"]
@@ -13,22 +13,20 @@ ms.author: "corob"
1313
ms.workload: ["cplusplus"]
1414
---
1515
# /DYNAMICBASE
16-
Specifies whether an executable image can be randomly rebased at load time by using address space layout randomization (ASLR).
17-
18-
## Syntax
19-
20-
```
21-
22-
/DYNAMICBASE[:NO]
23-
```
24-
25-
## Remarks
26-
By default, the linker sets the **/DYNAMICBASE** option.
27-
28-
This option modifies the header of an executable image to indicate whether the loader can randomly rebase the image at load time.
29-
30-
ASLR is supported on Windows Vista, Windows Server 2008, Windows 7, Windows 8, and Windows Server 2012.
31-
32-
## See Also
33-
[EDITBIN Options](../../build/reference/editbin-options.md)
34-
[Windows ISV Software Security Defenses](http://msdn.microsoft.com/library/bb430720.aspx)
16+
17+
Specifies whether to generate an executable image that can be randomly rebased at load time by using the address space layout randomization (ASLR) feature of Windows that was first available in Windows Vista.
18+
19+
## Syntax
20+
21+
> **/DYNAMICBASE**[**:NO**]
22+
23+
## Remarks
24+
25+
The **/DYNAMICBASE** option modifies the header of an *executable image*, a .dll or .exe file, to indicate whether the application should be randomly rebased at load time, and enables virtual address allocation randomization, which affects the virtual memory location of heaps, stacks, and other operating system allocations. The **/DYNAMICBASE** option applies to both 32-bit and 64-bit images. ASLR is supported on Windows Vista and later operating systems. The option is ignored by earlier operating systems.
26+
27+
By default, **/DYNAMICBASE** is enabled. To disable this option, use **/DYNAMICBASE:NO**. The **/DYNAMICBASE** option is required for the [/HIGHENTROPYVA](highentropyva-support-64-bit-aslr.md) option to have an effect.
28+
29+
## See also
30+
31+
- [EDITBIN Options](../../build/reference/editbin-options.md)
32+
- [Windows ISV Software Security Defenses](http://msdn.microsoft.com/library/bb430720.aspx)
Lines changed: 32 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
2-
title: "-HIGHENTROPYVA (Support 64-Bit ASLR) | Microsoft Docs"
2+
title: "/HIGHENTROPYVA (Support 64-Bit ASLR) | Microsoft Docs"
33
ms.custom: ""
4-
ms.date: "11/04/2016"
4+
ms.date: "06/12/2018"
55
ms.technology: ["cpp-tools"]
66
ms.topic: "reference"
77
dev_langs: ["C++"]
@@ -11,31 +11,33 @@ ms.author: "corob"
1111
ms.workload: ["cplusplus"]
1212
---
1313
# /HIGHENTROPYVA (Support 64-Bit ASLR)
14-
Specifies that the executable image supports high-entropy 64-bit address space layout randomization (ASLR).
15-
16-
## Syntax
17-
18-
```
19-
/HIGHENTROPYVA[:NO]
20-
```
21-
22-
## Remarks
23-
By default, /HIGHENTROPYVA is on for 64-bit executable images. It is not applicable to 32-bit executable images. To enable this option, /DYNAMICBASE must also be on.
24-
25-
/HIGHENTROPYVA modifies the header of a .dll file or .exe file to indicate whether ASLR with 64-bit addresses is supported. When this option is set on an executable and all of the modules that it depends on, an operating system that supports 64-bit ASLR can rebase the segments of the executable image at load time by using randomized addresses in a 64-bit virtual address space. This large address space makes it more difficult for an attacker to guess the location of a particular memory region.
26-
27-
### To set this linker option in Visual Studio
28-
29-
1. Open the project **Property Pages** dialog box. For more information, see [Working with Project Properties](../../ide/working-with-project-properties.md).
30-
31-
2. Expand the **Configuration Properties** node.
32-
33-
3. Expand the **Linker** node.
34-
35-
4. Select the **Command Line** property page.
36-
37-
5. In **Additional Options**, enter `/HIGHENTROPYVA` or `/HIGHENTROPYVA:NO`.
38-
39-
## See Also
40-
[Setting Linker Options](../../build/reference/setting-linker-options.md)
41-
[Linker Options](../../build/reference/linker-options.md)
14+
15+
Specifies whether the executable image supports high-entropy 64-bit address space layout randomization (ASLR).
16+
17+
## Syntax
18+
19+
> **/HIGHENTROPYVA**[**:NO**]
20+
21+
## Remarks
22+
23+
**/HIGHENTROPYVA** modifies the header of an *executable image*, a .dll file or .exe file, to indicate whether ASLR can use the entire 64-bit address space. When this option is set on an executable and all of the modules that it depends on, an operating system that supports 64-bit ASLR can rebase the segments of the executable image at load time by using randomized addresses in a 64-bit virtual address space. This large address space makes it more difficult for an attacker to guess the location of a particular memory region.
24+
25+
By default, **/HIGHENTROPYVA** is enabled for 64-bit executable images. This option requires [/LARGEADDRESSAWARE](largeaddressaware-handle-large-addresses.md), which is also enabled by default for 64-bit images. **/HIGHENTROPYVA** is not applicable to 32-bit executable images, where the linker ignores the option. To explicitly disable this option, use **/HIGHENTROPYVA:NO**.
26+
27+
For **/HIGHENTROPYVA** to have an effect at load time, [/DYNAMICBASE](dynamicbase-use-address-space-layout-randomization.md) must also be enabled. **/DYNAMICBASE** is enabled by default, and is required to enable ASLR in Windows Vista and later operating systems. Earlier versions of Windows ignore this flag.
28+
29+
### To set this linker option in Visual Studio
30+
31+
1. Open the project **Property Pages** dialog box. For more information, see [Working with Project Properties](../../ide/working-with-project-properties.md).
32+
33+
1. Select the **Configuration Properties** > **Linker** > **Command Line** property page.
34+
35+
1. In **Additional Options**, enter `/HIGHENTROPYVA` or `/HIGHENTROPYVA:NO`.
36+
37+
## See also
38+
39+
- [Setting Linker Options](../../build/reference/setting-linker-options.md)
40+
- [Linker Options](../../build/reference/linker-options.md)
41+
- [/DYNAMICBASE](dynamicbase-use-address-space-layout-randomization.md)
42+
- [/LARGEADDRESSAWARE](largeaddressaware-handle-large-addresses.md)
43+
- [Windows ISV Software Security Defenses](http://msdn.microsoft.com/library/bb430720.aspx)
Lines changed: 19 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
---
22
title: "-HIGHENTROPYVA | Microsoft Docs"
33
ms.custom: ""
4-
ms.date: "11/04/2016"
4+
ms.date: "06/12/2018"
55
ms.technology: ["cpp-tools"]
66
ms.topic: "reference"
77
f1_keywords: ["/HIGHENTROPYVA"]
@@ -13,19 +13,21 @@ ms.author: "corob"
1313
ms.workload: ["cplusplus"]
1414
---
1515
# /HIGHENTROPYVA
16-
Specifies whether the executable image supports high-entropy 64-bit address space layout randomization (ASLR).
17-
18-
```
19-
20-
/HIGHENTROPYVA[:NO]
21-
```
22-
23-
## Remarks
24-
This option modifies the header of a .dll file or .exe file to indicate whether ASLR with 64-bit addresses is supported. When this option is set on an executable and all of the modules that it depends on, an operating system that supports 64-bit ASLR can rebase the segments of the executable image at load time by using randomized addresses in a 64-bit virtual address space. This large address space makes it more difficult for an attacker to guess the location of a particular memory region.
25-
26-
By default, the linker sets this option for 64-bit executable images. To set this option, the [/DYNAMICBASE](../../build/reference/dynamicbase.md) option must also be set.
27-
28-
## See Also
29-
[EDITBIN Options](../../build/reference/editbin-options.md)
30-
[/DYNAMICBASE](../../build/reference/dynamicbase.md)
31-
[Windows ISV Software Security Defenses](http://msdn.microsoft.com/library/bb430720.aspx)
16+
17+
Specifies whether the executable image supports high-entropy 64-bit address space layout randomization (ASLR).
18+
19+
## Syntax
20+
21+
> **/HIGHENTROPYVA**[**:NO**]
22+
23+
## Remarks
24+
25+
This option modifies the header of an *executable image*, a .dll file or .exe file, to indicate whether ASLR with 64-bit addresses is supported. When this option is set on an executable and all of the modules that it depends on, an operating system that supports 64-bit ASLR can rebase the segments of the executable image at load time by using randomized addresses in a 64-bit virtual address space. This large address space makes it more difficult for an attacker to guess the location of a particular memory region.
26+
27+
By default, the linker enables **/HIGHENTROPYVA** for 64-bit executable images. This option requires [/LARGEADDRESSAWARE](largeaddressaware.md), which is also enabled by default for 64-bit images. **/HIGHENTROPYVA** is not applicable to 32-bit executable images, where the option is ignored. To explicitly disable this option, use **/HIGHENTROPYVA:NO**. For this option to have an effect, the [/DYNAMICBASE](dynamicbase.md) option must also be set.
28+
29+
## See also
30+
31+
- [EDITBIN Options](editbin-options.md)
32+
- [/DYNAMICBASE](dynamicbase.md)
33+
- [Windows ISV Software Security Defenses](http://msdn.microsoft.com/library/bb430720.aspx)

0 commit comments

Comments
 (0)