···21211. Update `all-packages.nix` to add `kanidm_1_5` and `kanidmWithSecretProvisioning_1_5`, leave default22221. Create commit, `kanidm_1_5: init at 1.5.0` - this is the only commit that will be backported23232424-### Mark previous version deprecated2525-2626-1. Update `pkgs/by-name/ka/kanidm/1_4.nix` by adding `deprecated = true;`2727-1. Create commit `kanidm_1_4: update default to 1.5.0, deprecate 1.4.0`2828-2929-### Update default and mark deprecation2424+### Update default302531261. `sed -i 's/1_4/1_5/' pkgs/by-name/ka/kanidm/package.nix`32271. Update `all-packages.nix` and set `kanidmWithSecretProvisioning = kanidmWithSecretProvisioning_1_5;`···3641Kanidm versions are supported for 30 days after the release of new versions. Following the example above, 1.5.x superseding 1.4.x in 30 days, do the following near the end of the 30 day window374238431. Update `pkgs/by-name/ka/kanidm/1_4.nix` by adding `unsupported = true;`3939-1. Update `pkgs/top-level/release.nix` and add `kanidm_1_4-1.4.6` to `permittedInsecurePackages`4444+1. Update `pkgs/top-level/release.nix` and add `kanidm_1_4-1.4.6` and `kanidmWithSecretProvisioning_1_4-1.4.6` to `permittedInsecurePackages`40451. Create commit `kanidm_1_4: mark EOL`, this commit alone should be backported414642471. Remove the third oldest release from `all-packages.nix`, e.g. 1.3.x continuing the example. Remove `kanidm_1_3` and `kanidmWithSecretProvisioning_1_3`4343-1. Update `pkgs/top-level/release.nix` and remove `kanidm_1_3-1.3.3` from `permittedInsecurePackages`4848+1. Update `pkgs/top-level/release.nix` and remove `kanidm_1_3*` from `permittedInsecurePackages`4949+1. Update `pkgs/top-level/aliases.nix` and add `kanidm_1_4` and `kanidmWithSecretProvisioning_1_4-1.4.6`44501. Remove `pkgs/by-name/ka/kanidm/1_3.nix`
···11-From c8ed69efe3f702b19834c2659be1dd3ec2d41c17 Mon Sep 17 00:00:00 200122-From: oddlama <oddlama@oddlama.org>33-Date: Fri, 1 Nov 2024 12:27:43 +010044-Subject: [PATCH 2/2] recover account55-66----77- server/core/src/actors/internal.rs | 3 ++-88- server/core/src/admin.rs | 6 +++---99- server/daemon/src/main.rs | 14 +++++++++++++-1010- server/daemon/src/opt.rs | 4 ++++1111- 4 files changed, 22 insertions(+), 5 deletions(-)1212-1313-diff --git a/server/core/src/actors/internal.rs b/server/core/src/actors/internal.rs1414-index 420e72c6c..5c4353116 1006441515---- a/server/core/src/actors/internal.rs1616-+++ b/server/core/src/actors/internal.rs1717-@@ -171,25 +171,26 @@ impl QueryServerWriteV1 {1818- }1919-2020- #[instrument(2121- level = "info",2222-- skip(self, eventid),2323-+ skip(self, password, eventid),2424- fields(uuid = ?eventid)2525- )]2626- pub(crate) async fn handle_admin_recover_account(2727- &self,2828- name: String,2929-+ password: Option<String>,3030- eventid: Uuid,3131- ) -> Result<String, OperationError> {3232- let ct = duration_from_epoch_now();3333- let mut idms_prox_write = self.idms.proxy_write(ct).await?;3434-- let pw = idms_prox_write.recover_account(name.as_str(), None)?;3535-+ let pw = idms_prox_write.recover_account(name.as_str(), password.as_deref())?;3636-3737- idms_prox_write.commit().map(|()| pw)3838- }3939-4040- #[instrument(4141- level = "info",4242- skip_all,4343- fields(uuid = ?eventid)4444- )]4545- pub(crate) async fn handle_domain_raise(&self, eventid: Uuid) -> Result<u32, OperationError> {4646-diff --git a/server/core/src/admin.rs b/server/core/src/admin.rs4747-index 90ccb1927..85e31ddef 1006444848---- a/server/core/src/admin.rs4949-+++ b/server/core/src/admin.rs5050-@@ -17,21 +17,21 @@ use tokio_util::codec::{Decoder, Encoder, Framed};5151- use tracing::{span, Instrument, Level};5252- use uuid::Uuid;5353-5454- pub use kanidm_proto::internal::{5555- DomainInfo as ProtoDomainInfo, DomainUpgradeCheckReport as ProtoDomainUpgradeCheckReport,5656- DomainUpgradeCheckStatus as ProtoDomainUpgradeCheckStatus,5757- };5858-5959- #[derive(Serialize, Deserialize, Debug)]6060- pub enum AdminTaskRequest {6161-- RecoverAccount { name: String },6262-+ RecoverAccount { name: String, password: Option<String> },6363- ShowReplicationCertificate,6464- RenewReplicationCertificate,6565- RefreshReplicationConsumer,6666- DomainShow,6767- DomainUpgradeCheck,6868- DomainRaise,6969- DomainRemigrate { level: Option<u32> },7070- }7171-7272- #[derive(Serialize, Deserialize, Debug)]7373-@@ -302,22 +302,22 @@ async fn handle_client(7474- let mut reqs = Framed::new(sock, ServerCodec);7575-7676- trace!("Waiting for requests ...");7777- while let Some(Ok(req)) = reqs.next().await {7878- // Setup the logging span7979- let eventid = Uuid::new_v4();8080- let nspan = span!(Level::INFO, "handle_admin_client_request", uuid = ?eventid);8181-8282- let resp = async {8383- match req {8484-- AdminTaskRequest::RecoverAccount { name } => {8585-- match server_rw.handle_admin_recover_account(name, eventid).await {8686-+ AdminTaskRequest::RecoverAccount { name, password } => {8787-+ match server_rw.handle_admin_recover_account(name, password, eventid).await {8888- Ok(password) => AdminTaskResponse::RecoverAccount { password },8989- Err(e) => {9090- error!(err = ?e, "error during recover-account");9191- AdminTaskResponse::Error9292- }9393- }9494- }9595- AdminTaskRequest::ShowReplicationCertificate => match repl_ctrl_tx.as_mut() {9696- Some(ctrl_tx) => show_replication_certificate(ctrl_tx).await,9797- None => {9898-diff --git a/server/daemon/src/main.rs b/server/daemon/src/main.rs9999-index 7486d34a8..784106352 100644100100---- a/server/daemon/src/main.rs101101-+++ b/server/daemon/src/main.rs102102-@@ -903,27 +903,39 @@ async fn kanidm_main(103103- } else {104104- let output_mode: ConsoleOutputMode = commonopts.output_mode.to_owned().into();105105- submit_admin_req(106106- config.adminbindpath.as_str(),107107- AdminTaskRequest::RefreshReplicationConsumer,108108- output_mode,109109- )110110- .await;111111- }112112- }113113-- KanidmdOpt::RecoverAccount { name, commonopts } => {114114-+ KanidmdOpt::RecoverAccount { name, from_environment, commonopts } => {115115- info!("Running account recovery ...");116116- let output_mode: ConsoleOutputMode = commonopts.output_mode.to_owned().into();117117-+ let password = if *from_environment {118118-+ match std::env::var("KANIDM_RECOVER_ACCOUNT_PASSWORD") {119119-+ Ok(val) => Some(val),120120-+ _ => {121121-+ error!("Environment variable KANIDM_RECOVER_ACCOUNT_PASSWORD not set");122122-+ return ExitCode::FAILURE;123123-+ }124124-+ }125125-+ } else {126126-+ None127127-+ };128128- submit_admin_req(129129- config.adminbindpath.as_str(),130130- AdminTaskRequest::RecoverAccount {131131- name: name.to_owned(),132132-+ password,133133- },134134- output_mode,135135- )136136- .await;137137- }138138- KanidmdOpt::Database {139139- commands: DbCommands::Reindex(_copt),140140- } => {141141- info!("Running in reindex mode ...");142142- reindex_server_core(&config).await;143143-diff --git a/server/daemon/src/opt.rs b/server/daemon/src/opt.rs144144-index f1b45a5b3..9c013e32e 100644145145---- a/server/daemon/src/opt.rs146146-+++ b/server/daemon/src/opt.rs147147-@@ -229,20 +229,24 @@ enum KanidmdOpt {148148- /// Create a self-signed ca and tls certificate in the locations listed from the149149- /// configuration. These certificates should *not* be used in production, they150150- /// are for testing and evaluation only!151151- CertGenerate(CommonOpt),152152- #[clap(name = "recover-account")]153153- /// Recover an account's password154154- RecoverAccount {155155- #[clap(value_parser)]156156- /// The account name to recover credentials for.157157- name: String,158158-+ /// Use the password given in the environment variable159159-+ /// `KANIDM_RECOVER_ACCOUNT_PASSWORD` instead of generating one.160160-+ #[clap(long = "from-environment")]161161-+ from_environment: bool,162162- #[clap(flatten)]163163- commonopts: CommonOpt,164164- },165165- /// Display this server's replication certificate166166- ShowReplicationCertificate {167167- #[clap(flatten)]168168- commonopts: CommonOpt,169169- },170170- /// Renew this server's replication certificate171171- RenewReplicationCertificate {172172--- 173173-2.46.1174174-
+2
pkgs/top-level/aliases.nix
···973973 kafkacat = throw "'kafkacat' has been renamed to/replaced by 'kcat'"; # Converted to throw 2024-10-17974974 kak-lsp = kakoune-lsp; # Added 2024-04-01975975 kanidm_1_3 = throw "'kanidm_1_3' has been removed as it has reached end of life"; # Added 2025-03-10976976+ kanidm_1_4 = throw "'kanidm_1_4' has been removed as it has reached end of life"; # Added 2025-06-18977977+ kanidmWithSecretProvisioning_1_4 = throw "'kanidmWithSecretProvisioning_1_4' has been removed as it has reached end of life"; # Added 2025-06-18976978 kdbplus = throw "'kdbplus' has been removed from nixpkgs"; # Added 2024-05-06977979 kdeconnect = throw "'kdeconnect' has been renamed to/replaced by 'plasma5Packages.kdeconnect-kde'"; # Converted to throw 2024-10-17978980 keepkey_agent = keepkey-agent; # added 2024-01-06
···4343 # so users choosing to allow don't have to rebuild them every time.4444 permittedInsecurePackages = [4545 "olm-3.2.16" # see PR #3478994646- "kanidm_1_4-1.4.6"4646+ "kanidm_1_5-1.5.0"4747+ "kanidmWithSecretProvisioning_1_5-1.5.0"4748 ];4849 };4950