Skip to content

Commit

Permalink
Merge branch 'release/3.x/3.10.0' into 3.x-master
Browse files Browse the repository at this point in the history
  • Loading branch information
Tara committed Mar 25, 2024
2 parents 309ea61 + 0169868 commit c0ff656
Show file tree
Hide file tree
Showing 4 changed files with 38 additions and 19 deletions.
24 changes: 6 additions & 18 deletions composer.json
Expand Up @@ -14,26 +14,14 @@
{
"type": "composer",
"url": "https://packages.drupal.org/8"
},
{
"type": "package",
"package": {
"name": "dropzone/dropzone",
"version": "v5.7.2",
"type": "drupal-library",
"dist": {
"type": "zip",
"url": "https://github.com/dropzone/dropzone/archive/refs/tags/v5.7.2.zip"
}
}
}
],
"require": {
"php": "^8.1.0",
"composer/installers": "^2.0",
"cweagans/composer-patches": "^1.7",
"dropzone/dropzone": "5.7.2",
"drupal/address": "2.0.0",
"govcms-assets/dropzone": "5.7.2",
"drupal/address": "2.0.1",
"drupal/admin_toolbar": "3.4.2",
"drupal/bigmenu": "2.0.0-rc3",
"drupal/captcha": "2.0.5",
Expand All @@ -54,7 +42,7 @@
"drupal/ctools": "3.14.0",
"drupal/devel": "5.1.2",
"drupal/diff": "1.1.0",
"drupal/dropzonejs": "2.8.0",
"drupal/dropzonejs": "2.10.0",
"drupal/ds": "3.19.0",
"drupal/dynamic_entity_reference": "3.2.0",
"drupal/embed": "1.7.0",
Expand All @@ -67,7 +55,7 @@
"drupal/entity_reference_revisions": "1.11.0",
"drupal/environment_indicator": "4.0.17",
"drupal/events_log_track": "3.1.9",
"drupal/facets": "2.0.6",
"drupal/facets": "2.0.7",
"drupal/field_group": "3.4.0",
"drupal/focal_point": "2.0.2",
"drupal/google_analytics": "4.0.2",
Expand Down Expand Up @@ -104,7 +92,7 @@
"drupal/rest_menu_items": "3.0.3",
"drupal/robotstxt": "1.5.0",
"drupal/role_delegation": "1.2.0",
"drupal/scheduled_transitions": "2.3.0",
"drupal/scheduled_transitions": "2.4.1",
"drupal/search_api": "1.31.0",
"drupal/search_api_attachments": "9.0.2",
"drupal/search_api_solr": "4.3.1",
Expand All @@ -116,7 +104,7 @@
"drupal/symfony_mailer": "1.4.1",
"drupal/tfa": "1.5.0",
"drupal/token": "1.13.0",
"drupal/twig_tweak": "3.2.1",
"drupal/twig_tweak": "3.3.0",
"drupal/username_enumeration_prevention": "1.3.0",
"drupal/webform": "6.2.2",
"govcms-assets/chosen": "2.2.1",
Expand Down
2 changes: 1 addition & 1 deletion govcms.info.yml
Expand Up @@ -3,7 +3,7 @@ type: profile
description: 'A GovCMS Drupal Distribution for government and the public sector in Australia.'
core_version_requirement: ^10
project: 'govcms'
version: '3.9.0'
version: '3.10.0'

distribution:
name: GovCMS
Expand Down
27 changes: 27 additions & 0 deletions modules/custom/core/govcms_security/govcms_security.module
Expand Up @@ -113,6 +113,19 @@ function govcms_security_form_tfa_settings_form_alter(&$form, FormStateInterface
$form['validation_skip']['#max'] = 10;
}

/**
* Implement hook_form_FORM_ID_alter()
*
* Disable the Import all button for all users from User Interface.
* Display a message around disabled config synchronization.
*
*/
function govcms_security_form_config_admin_import_form_alter(&$form, FormStateInterface $form_state) {
$form['actions']['submit']['#access'] = FALSE;
\Drupal::messenger()->addMessage("Configuration import is blocked via govcms_security module.");
}


/**
* Implements hook_form_alter().
*/
Expand Down Expand Up @@ -226,3 +239,17 @@ function govcms_security_cron() {
\Drupal::keyValueExpirable('update_available_releases')->deleteAll();
\Drupal::keyValueExpirable('update_available_releases')->setMultiple([]);
}

/**
* Implements hook_form_BASE_FORM_ID_alter() for tfa_base_overview form.
*/
function govcms_security_form_tfa_base_overview_alter(&$form, FormStateInterface $form_state, $form_id) : void {
// Ensure that the Reset TFA skip count button is only available to privileged
// users with the 'reset TFA skip count' permission.
if (\Drupal::currentUser()->hasPermission('reset TFA skip count')) {
return;
}
if (isset($form['actions']['reset_skip_attempts'])) {
$form['actions']['reset_skip_attempts']['#access'] = FALSE;
}
}
@@ -0,0 +1,4 @@
reset TFA skip count:
title: 'Reset TFA Skip validation attempts'
description: 'Only users with this permission can reset the TFA skip validation attempts.'
restrict access: true

0 comments on commit c0ff656

Please sign in to comment.