[BUGFIX] Ensure uniqid calls use more_entropy
Precision of `uniqid()` on Windows systems without passing `$more_entropy=true` has only single-second-resolution which will lead to non-unique ids on subsequent calls. In order to mitigate this issue TYPO3 provides the function `StringUtility::getUniqueId($prefix = '')` which calls `uniqid()` with parameter `$more_entropy` always set to true. Using `uniqid()`, especially with `$more_entropy` set to true, is quite slow, but for the purposes TYPO3 is using it (i.e. creating unique field names for backend forms, path identifiers in some modules etc.) it is good enough and another solution would not provide any measurable benefit. Resolves: #91553 Releases: master, 10.4 Change-Id: Ib4443e72621eee6df2daf5bf23054e1a01325783 Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/64652 Tested-by:TYPO3com <noreply@typo3.com> Tested-by:
Jörg Bösche <typo3@joergboesche.de> Tested-by:
Alexander Schnitzler <git@alexanderschnitzler.de> Tested-by:
Oliver Bartsch <bo@cedev.de> Tested-by:
Christian Kuhn <lolli@schwarzbu.ch> Reviewed-by:
Jörg Bösche <typo3@joergboesche.de> Reviewed-by:
Alexander Schnitzler <git@alexanderschnitzler.de> Reviewed-by:
Oliver Bartsch <bo@cedev.de> Reviewed-by:
Christian Kuhn <lolli@schwarzbu.ch>
Showing
- typo3/sysext/adminpanel/Classes/Middleware/AdminPanelInitiator.php 2 additions, 1 deletion...ext/adminpanel/Classes/Middleware/AdminPanelInitiator.php
- typo3/sysext/backend/Classes/Controller/ContentElement/NewContentElementController.php 2 additions, 1 deletion...Controller/ContentElement/NewContentElementController.php
- typo3/sysext/backend/Classes/Controller/SiteConfigurationController.php 2 additions, 1 deletion...ackend/Classes/Controller/SiteConfigurationController.php
- typo3/sysext/backend/Classes/Form/Element/SelectCheckBoxElement.php 1 addition, 1 deletion...xt/backend/Classes/Form/Element/SelectCheckBoxElement.php
- typo3/sysext/backend/Tests/Unit/Routing/UriBuilderTest.php 2 additions, 1 deletiontypo3/sysext/backend/Tests/Unit/Routing/UriBuilderTest.php
- typo3/sysext/core/Classes/Core/Bootstrap.php 2 additions, 1 deletiontypo3/sysext/core/Classes/Core/Bootstrap.php
- typo3/sysext/core/Classes/Imaging/GraphicalFunctions.php 3 additions, 2 deletionstypo3/sysext/core/Classes/Imaging/GraphicalFunctions.php
- typo3/sysext/core/Classes/Resource/ResourceStorage.php 2 additions, 1 deletiontypo3/sysext/core/Classes/Resource/ResourceStorage.php
- typo3/sysext/core/Classes/Resource/Search/FileSearchQuery.php 2 additions, 1 deletion...3/sysext/core/Classes/Resource/Search/FileSearchQuery.php
- typo3/sysext/core/Classes/Utility/File/BasicFileUtility.php 2 additions, 1 deletiontypo3/sysext/core/Classes/Utility/File/BasicFileUtility.php
- typo3/sysext/core/Tests/Unit/Imaging/IconProvider/SvgIconProviderTest.php 2 additions, 2 deletions...e/Tests/Unit/Imaging/IconProvider/SvgIconProviderTest.php
- typo3/sysext/fluid/Classes/Core/Widget/AjaxWidgetContextHolder.php 2 additions, 1 deletion...ext/fluid/Classes/Core/Widget/AjaxWidgetContextHolder.php
- typo3/sysext/form/Classes/Mvc/Property/TypeConverter/UploadedFileReferenceConverter.php 3 additions, 2 deletions...Property/TypeConverter/UploadedFileReferenceConverter.php
- typo3/sysext/form/Classes/ViewHelpers/Form/DatePickerViewHelper.php 2 additions, 1 deletion...xt/form/Classes/ViewHelpers/Form/DatePickerViewHelper.php
- typo3/sysext/install/Classes/Controller/UpgradeController.php 3 additions, 2 deletions...3/sysext/install/Classes/Controller/UpgradeController.php
- typo3/sysext/install/Tests/Functional/Service/Typo3tempFileServiceTest.php 2 additions, 1 deletion...all/Tests/Functional/Service/Typo3tempFileServiceTest.php
- typo3/sysext/workspaces/Classes/Controller/Remote/RemoteServer.php 2 additions, 1 deletion...ext/workspaces/Classes/Controller/Remote/RemoteServer.php
- typo3/sysext/workspaces/Classes/Preview/PreviewUriBuilder.php 2 additions, 1 deletion...3/sysext/workspaces/Classes/Preview/PreviewUriBuilder.php
Please register or sign in to comment