dns_dynu: use mutable conf storage so newly exported credentials win

Same stale-account.conf override as dns_dnsimple: the sourced plain
copy shadowed newly exported Dynu_ClientId/Dynu_Secret.

https://github.com/acmesh-official/acme.sh/issues/3216
This commit is contained in:
neil committed 2026-07-12 19:21:56 +08:00
1 parent a6766d4186
commit 3fddea2962
1 file changed
+8 -4
+8 -4
View File
@@ -23,6 +23,8 @@ dns_dynu_add() {
fulldomain=$1 fulldomain=$1
txtvalue=$2 txtvalue=$2
Dynu_ClientId="${Dynu_ClientId:-$(_readaccountconf_mutable Dynu_ClientId)}"
Dynu_Secret="${Dynu_Secret:-$(_readaccountconf_mutable Dynu_Secret)}"
if [ -z "$Dynu_ClientId" ] || [ -z "$Dynu_Secret" ]; then if [ -z "$Dynu_ClientId" ] || [ -z "$Dynu_Secret" ]; then
Dynu_ClientId="" Dynu_ClientId=""
Dynu_Secret="" Dynu_Secret=""
@@ -32,8 +34,8 @@ dns_dynu_add() {
fi fi
#save the client id and secret to the account conf file. #save the client id and secret to the account conf file.
_saveaccountconf Dynu_ClientId "$Dynu_ClientId" _saveaccountconf_mutable Dynu_ClientId "$Dynu_ClientId"
_saveaccountconf Dynu_Secret "$Dynu_Secret" _saveaccountconf_mutable Dynu_Secret "$Dynu_Secret"
if [ -z "$Dynu_Token" ]; then if [ -z "$Dynu_Token" ]; then
_info "Getting Dynu token." _info "Getting Dynu token."
@@ -69,6 +71,8 @@ dns_dynu_rm() {
fulldomain=$1 fulldomain=$1
txtvalue=$2 txtvalue=$2
Dynu_ClientId="${Dynu_ClientId:-$(_readaccountconf_mutable Dynu_ClientId)}"
Dynu_Secret="${Dynu_Secret:-$(_readaccountconf_mutable Dynu_Secret)}"
if [ -z "$Dynu_ClientId" ] || [ -z "$Dynu_Secret" ]; then if [ -z "$Dynu_ClientId" ] || [ -z "$Dynu_Secret" ]; then
Dynu_ClientId="" Dynu_ClientId=""
Dynu_Secret="" Dynu_Secret=""
@@ -78,8 +82,8 @@ dns_dynu_rm() {
fi fi
#save the client id and secret to the account conf file. #save the client id and secret to the account conf file.
_saveaccountconf Dynu_ClientId "$Dynu_ClientId" _saveaccountconf_mutable Dynu_ClientId "$Dynu_ClientId"
_saveaccountconf Dynu_Secret "$Dynu_Secret" _saveaccountconf_mutable Dynu_Secret "$Dynu_Secret"
if [ -z "$Dynu_Token" ]; then if [ -z "$Dynu_Token" ]; then
_info "Getting Dynu token." _info "Getting Dynu token."
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.