services:
  _defaults:
    autowire: true
    autoconfigure: true
    public: false

  TYPO3\CMS\Backend\:
    resource: '../Classes/*'

  TYPO3\CMS\Backend\Command\LockBackendCommand:
    tags:
      - { name: 'console.command', command: 'backend:lock', description: 'Lock the TYPO3 Backend' }

  TYPO3\CMS\Backend\Command\UnlockBackendCommand:
    tags:
      - { name: 'console.command', command: 'backend:unlock', description: 'Unlock the TYPO3 Backend' }

  TYPO3\CMS\Backend\Command\ReferenceIndexUpdateCommand:
    tags:
      - { name: 'console.command', command: 'referenceindex:update', description: 'Update the reference index of TYPO3' }

  TYPO3\CMS\Backend\Command\ResetPasswordCommand:
    tags:
      - { name: 'console.command', command: 'backend:resetpassword', description: 'Trigger a password reset for a backend user', schedulable: false }

  TYPO3\CMS\Backend\Command\CreateBackendUserCommand:
    tags:
      - { name: 'console.command', command: 'backend:user:create', description: 'Create a backend user', schedulable: false }

  TYPO3\CMS\Backend\Middleware\ContentSecurityPolicyHeaders:
    arguments:
      $cache: '@cache.assets'

  TYPO3\CMS\Backend\Backend\Avatar\Avatar:
    public: true
    arguments:
      $cache: '@cache.runtime'

  TYPO3\CMS\Backend\Clipboard\Clipboard:
    shared: false
    public: true

  TYPO3\CMS\Backend\ContextMenu\ContextMenu:
    public: true

  TYPO3\CMS\Backend\ContextMenu\ImportMapConfigurator:
    tags:
      - name: event.listener

  TYPO3\CMS\Backend\ContextMenu\ItemProviders\ItemProvidersRegistry:
    arguments:
      - !tagged_iterator backend.contextmenu.itemprovider

  # ModuleTemplate instantiated using factory.
  TYPO3\CMS\Backend\Template\ModuleTemplate: ~

  # Not a service, not injectable
  TYPO3\CMS\Backend\Module\ModuleInterface: ~

  TYPO3\CMS\Backend\Template\ModuleTemplateFactory:
    shared: false
    public: true

  TYPO3\CMS\Backend\Controller\LinkBrowserController:
    shared: false
    public: true

  TYPO3\CMS\Backend\Controller\File\ImageProcessController:
    shared: false
    public: true

  TYPO3\CMS\Backend\History\RecordHistoryRollback:
    public: true

  TYPO3\CMS\Backend\Backend\Shortcut\ShortcutRepository:
    public: true

  TYPO3\CMS\Backend\View\AuthenticationStyleInformation:
    public: true

  TYPO3\CMS\Backend\Search\LiveSearch\SearchProviderRegistry:
    arguments:
      - !tagged_iterator livesearch.provider

  TYPO3\CMS\Backend\Search\LiveSearch\DatabaseRecordProvider:
    tags:
      - { name: 'livesearch.provider', priority: 50 }

  TYPO3\CMS\Backend\Search\LiveSearch\PageRecordProvider:
    tags:
      - { name: 'livesearch.provider', priority: 60 }

  TYPO3\CMS\Backend\Form\FormDataProvider\ReturnUrl:
    public: true

  TYPO3\CMS\Backend\Form\FormDataProvider\SiteDatabaseEditRow:
    public: true

  TYPO3\CMS\Backend\Form\FormDataProvider\SystemMaintainerAsReadonly:
    public: true

  TYPO3\CMS\Backend\RecordList\DatabaseRecordList:
    shared: false
    public: true

  TYPO3\CMS\Backend\RecordList\ElementBrowserRecordList:
    shared: false
    public: true

  TYPO3\CMS\Backend\ElementBrowser\DatabaseBrowser:
    shared: false

  TYPO3\CMS\Backend\ElementBrowser\ElementBrowserRegistry:
    arguments:
      - !tagged_iterator recordlist.elementbrowser

  TYPO3\CMS\Backend\Resource\PublicUrlPrefixer:
    public: true

  TYPO3\CMS\Backend\Backend\ToolbarItems\ClearCacheToolbarItem:
    public: true

  TYPO3\CMS\Backend\Backend\ToolbarItems\ShortcutToolbarItem:
    public: true

  TYPO3\CMS\Backend\Backend\ToolbarItems\SystemInformationToolbarItem:
    public: true

  TYPO3\CMS\Recordlist\LinkHandler\RecordLinkHandler:
    alias: TYPO3\CMS\Backend\LinkHandler\RecordLinkHandler
    public: true
    deprecated:
      package: 'typo3/cms-backend'
      version: '12.0'
      message: 'Usage of "%alias_id%" is deprecated. Please use "TYPO3\CMS\Backend\LinkHandler\RecordLinkHandler" instead.'

  TYPO3\CMS\Backend\LinkHandler\RecordLinkHandler:
    shared: false
    public: true

  TYPO3\CMS\Backend\Tree\View\ContentCreationPagePositionMap:
    public: true

  TYPO3\CMS\Backend\Tree\View\ContentMovingPagePositionMap:
    public: true

  # Category security checks for backend users
  TYPO3\CMS\Backend\Security\CategoryPermissionsAspect:
    tags:
      - name: event.listener
        identifier: 'backend-user-permissions'
        method: 'addUserPermissionsToCategoryTreeData'

  TYPO3\CMS\Backend\Security\SudoMode\Access\AccessFactory:
    public: true

  TYPO3\CMS\Backend\Security\SudoMode\Access\AccessStorage:
    public: true

  # Listener to provide information about column without a colPos set
  TYPO3\CMS\Backend\View\PageLayoutViewDrawEmptyColposContent:
    tags:
      - name: event.listener
        identifier: 'backend-empty-colpos'

  TYPO3\CMS\Backend\EventListener\AfterBackendPageRenderEventListener:
    tags:
      - name: event.listener
        event: TYPO3\CMS\Backend\Controller\Event\AfterBackendPageRenderEvent

  TYPO3\CMS\Backend\Search\EventListener\AddLiveSearchResultActionsListener:
    tags:
      -
        name: event.listener
        identifier: 'typo3/cms-backend/add-live-search-result-actions-listener'

  TYPO3\CMS\Backend\Search\EventListener\ExcludePagesFromSearchFieldsLookup:
    tags:
      -
        name: event.listener
        identifier: 'typo3/cms-backend/exclude-pages-from-search-fields-lookup'

  TYPO3\CMS\Backend\View\RecordSearchBoxComponent:
    shared: false
    public: true

  TYPO3\CMS\Backend\EventListener\FailedLoginAttemptNotification:
    tags:
      - name: event.listener
        identifier: 'typo3/cms-backend/failed-login-attempt-notification'
      - name: event.listener
        identifier: 'typo3/cms-backend/failed-mfa-verification-notification'

  TYPO3\CMS\Backend\Security\EmailLoginNotification:
    tags:
      - name: event.listener
        identifier: 'typo3/cms-backend/login-notification'
        method: 'emailAtLogin'

  TYPO3\CMS\Backend\EventListener\SilentSiteLanguageFlagMigration:
    tags:
      - name: event.listener
        event: TYPO3\CMS\Core\Configuration\Event\SiteConfigurationLoadedEvent

  # Toolbar registry
  TYPO3\CMS\Backend\Toolbar\ToolbarItemsRegistry:
    arguments:
      - !tagged_iterator backend.toolbar.item
