From 4b50f5171b314120835cd2620beb93b3058e1c11 Mon Sep 17 00:00:00 2001 From: jochen Date: Thu, 22 Oct 2026 21:42:46 +0200 Subject: [PATCH] Name no node in minio's and mailu's fixtures (issue 1838) --- modules/mailu/cmd/automx/automx_test.go | 18 +++--- .../01-thunderbird-autoconfig-ok.body | 2 +- ...1-thunderbird-autoconfig-ok.corrected.body | 2 +- .../01-thunderbird-autoconfig-ok.request | 2 +- .../02-thunderbird-on-automx-name.body | 2 +- ...-thunderbird-on-automx-name.corrected.body | 2 +- .../02-thunderbird-on-automx-name.request | 2 +- .../03-thunderbird-on-autodiscover-name.body | 2 +- ...erbird-on-autodiscover-name.corrected.body | 2 +- ...3-thunderbird-on-autodiscover-name.request | 2 +- .../04-thunderbird-unknown-domain.request | 2 +- ...5-thunderbird-missing-emailaddress.request | 2 +- .../captured/06-autoconfig-root.request | 2 +- .../07-wellknown-autoconfig-path.request | 2 +- .../08-outlook-post-known-domain.request | 4 +- .../09-outlook-post-unknown-domain.request | 2 +- .../10-outlook-post-malformed-body.request | 2 +- ...-outlook-post-missing-emailaddress.request | 2 +- .../12-outlook-get-not-allowed.request | 2 +- .../13-outlook-post-capitalised-path.request | 4 +- .../captured/14-mobileconfig-no-slash.body | 2 +- .../captured/14-mobileconfig-no-slash.headers | 4 +- .../captured/14-mobileconfig-no-slash.request | 2 +- .../15-mobileconfig-known-domain.request | 2 +- .../16-mobileconfig-unknown-domain.request | 2 +- ...-mobileconfig-missing-emailaddress.request | 2 +- .../cmd/automx/testdata/captured/CAPTURED | 10 ++-- .../cmd/automx/testdata/captured/DIFFERENCES | 2 +- modules/minio/cmd/object-store/server_test.go | 60 +++++++++---------- 29 files changed, 73 insertions(+), 73 deletions(-) diff --git a/modules/mailu/cmd/automx/automx_test.go b/modules/mailu/cmd/automx/automx_test.go index ab0ab5b6..984f7793 100644 --- a/modules/mailu/cmd/automx/automx_test.go +++ b/modules/mailu/cmd/automx/automx_test.go @@ -14,13 +14,13 @@ import ( "testing" ) -// The environment mailu gives automx on novox when the fixtures were captured (files/mailu.env): the mail domain, +// The environment mailu gives automx on node-c when the fixtures were captured (files/mailu.env): the mail domain, // the route name for both servers, the ports. var capturedEnvironment = map[string]string{ - "AMX_MAIL_DOMAINS": "novox.be", - "AMX_IMAP_ADDRESS": "mail.novox.be", + "AMX_MAIL_DOMAINS": "node-c.be", + "AMX_IMAP_ADDRESS": "mail.node-c.be", "AMX_IMAP_PORT": "143", - "AMX_SMTP_ADDRESS": "mail.novox.be", + "AMX_SMTP_ADDRESS": "mail.node-c.be", "AMX_SMTP_PORT": "587", "AUTOMX_PORT": "4243", } @@ -176,7 +176,7 @@ func TestTheOnlyCorrectedAnswerIsTheImapServersName(t *testing.T) { } for _, c := range corrected { orig := readFile(t, strings.TrimSuffix(c, ".corrected.body")+".body") - want := strings.Replace(orig, "", "mail.novox.be", 1) + want := strings.Replace(orig, "", "mail.node-c.be", 1) if strings.Contains(want, "") || want == orig { t.Fatalf("%s: the capture has no single empty hostname to correct", c) } @@ -198,12 +198,12 @@ func TestTheImapServerIsNamedFromTheImapAddress(t *testing.T) { t.Fatal(err) } rec := httptest.NewRecorder() - newHandler(cfg).ServeHTTP(rec, httptest.NewRequest("GET", "/mail/config-v1.1.xml?emailaddress=a@novox.be", nil)) + newHandler(cfg).ServeHTTP(rec, httptest.NewRequest("GET", "/mail/config-v1.1.xml?emailaddress=a@node-c.be", nil)) body := rec.Body.String() if !strings.Contains(body, `imap.example.test993`) { t.Errorf("incoming server not named from AMX_IMAP_ADDRESS and AMX_IMAP_PORT: %s", body) } - if !strings.Contains(body, `mail.novox.be587`) { + if !strings.Contains(body, `mail.node-c.be587`) { t.Errorf("outgoing server changed: %s", body) } } @@ -213,13 +213,13 @@ func TestEveryDomainOfTheEnvironmentIsServed(t *testing.T) { for k, v := range capturedEnvironment { env[k] = v } - env["AMX_MAIL_DOMAINS"] = "novox.be, example.test" + env["AMX_MAIL_DOMAINS"] = "node-c.be, example.test" cfg, err := configFrom(getenvOf(env)) if err != nil { t.Fatal(err) } h := newHandler(cfg) - for _, d := range []string{"novox.be", "example.test"} { + for _, d := range []string{"node-c.be", "example.test"} { rec := httptest.NewRecorder() h.ServeHTTP(rec, httptest.NewRequest("GET", "/mail/config-v1.1.xml?emailaddress=a@"+d, nil)) if rec.Code != 200 || !strings.Contains(rec.Body.String(), ""+d+"") { diff --git a/modules/mailu/cmd/automx/testdata/captured/01-thunderbird-autoconfig-ok.body b/modules/mailu/cmd/automx/testdata/captured/01-thunderbird-autoconfig-ok.body index 72d5c376..521dbf80 100644 --- a/modules/mailu/cmd/automx/testdata/captured/01-thunderbird-autoconfig-ok.body +++ b/modules/mailu/cmd/automx/testdata/captured/01-thunderbird-autoconfig-ok.body @@ -1 +1 @@ -novox.benovox.benovox.be143STARTTLS%EMAILADDRESS%password-cleartextmail.novox.be587STARTTLS%EMAILADDRESS%password-cleartext \ No newline at end of file +node-c.benode-c.benode-c.be143STARTTLS%EMAILADDRESS%password-cleartextmail.node-c.be587STARTTLS%EMAILADDRESS%password-cleartext \ No newline at end of file diff --git a/modules/mailu/cmd/automx/testdata/captured/01-thunderbird-autoconfig-ok.corrected.body b/modules/mailu/cmd/automx/testdata/captured/01-thunderbird-autoconfig-ok.corrected.body index 0adc5c4c..ad24a7a9 100644 --- a/modules/mailu/cmd/automx/testdata/captured/01-thunderbird-autoconfig-ok.corrected.body +++ b/modules/mailu/cmd/automx/testdata/captured/01-thunderbird-autoconfig-ok.corrected.body @@ -1 +1 @@ -novox.benovox.benovox.bemail.novox.be143STARTTLS%EMAILADDRESS%password-cleartextmail.novox.be587STARTTLS%EMAILADDRESS%password-cleartext \ No newline at end of file +node-c.benode-c.benode-c.bemail.node-c.be143STARTTLS%EMAILADDRESS%password-cleartextmail.node-c.be587STARTTLS%EMAILADDRESS%password-cleartext \ No newline at end of file diff --git a/modules/mailu/cmd/automx/testdata/captured/01-thunderbird-autoconfig-ok.request b/modules/mailu/cmd/automx/testdata/captured/01-thunderbird-autoconfig-ok.request index 98ae52c5..135ba262 100644 --- a/modules/mailu/cmd/automx/testdata/captured/01-thunderbird-autoconfig-ok.request +++ b/modules/mailu/cmd/automx/testdata/captured/01-thunderbird-autoconfig-ok.request @@ -1,3 +1,3 @@ -GET https://autoconfig.novox.be/mail/config-v1.1.xml?emailaddress=jochen@novox.be +GET https://autoconfig.node-c.be/mail/config-v1.1.xml?emailaddress=jochen@node-c.be User-Agent: Thunderbird Accept: */* diff --git a/modules/mailu/cmd/automx/testdata/captured/02-thunderbird-on-automx-name.body b/modules/mailu/cmd/automx/testdata/captured/02-thunderbird-on-automx-name.body index 72d5c376..521dbf80 100644 --- a/modules/mailu/cmd/automx/testdata/captured/02-thunderbird-on-automx-name.body +++ b/modules/mailu/cmd/automx/testdata/captured/02-thunderbird-on-automx-name.body @@ -1 +1 @@ -novox.benovox.benovox.be143STARTTLS%EMAILADDRESS%password-cleartextmail.novox.be587STARTTLS%EMAILADDRESS%password-cleartext \ No newline at end of file +node-c.benode-c.benode-c.be143STARTTLS%EMAILADDRESS%password-cleartextmail.node-c.be587STARTTLS%EMAILADDRESS%password-cleartext \ No newline at end of file diff --git a/modules/mailu/cmd/automx/testdata/captured/02-thunderbird-on-automx-name.corrected.body b/modules/mailu/cmd/automx/testdata/captured/02-thunderbird-on-automx-name.corrected.body index 0adc5c4c..ad24a7a9 100644 --- a/modules/mailu/cmd/automx/testdata/captured/02-thunderbird-on-automx-name.corrected.body +++ b/modules/mailu/cmd/automx/testdata/captured/02-thunderbird-on-automx-name.corrected.body @@ -1 +1 @@ -novox.benovox.benovox.bemail.novox.be143STARTTLS%EMAILADDRESS%password-cleartextmail.novox.be587STARTTLS%EMAILADDRESS%password-cleartext \ No newline at end of file +node-c.benode-c.benode-c.bemail.node-c.be143STARTTLS%EMAILADDRESS%password-cleartextmail.node-c.be587STARTTLS%EMAILADDRESS%password-cleartext \ No newline at end of file diff --git a/modules/mailu/cmd/automx/testdata/captured/02-thunderbird-on-automx-name.request b/modules/mailu/cmd/automx/testdata/captured/02-thunderbird-on-automx-name.request index 2a6405cf..9bc95279 100644 --- a/modules/mailu/cmd/automx/testdata/captured/02-thunderbird-on-automx-name.request +++ b/modules/mailu/cmd/automx/testdata/captured/02-thunderbird-on-automx-name.request @@ -1,2 +1,2 @@ -GET https://automx.novox.be/mail/config-v1.1.xml?emailaddress=jochen@novox.be +GET https://automx.node-c.be/mail/config-v1.1.xml?emailaddress=jochen@node-c.be User-Agent: Thunderbird diff --git a/modules/mailu/cmd/automx/testdata/captured/03-thunderbird-on-autodiscover-name.body b/modules/mailu/cmd/automx/testdata/captured/03-thunderbird-on-autodiscover-name.body index 72d5c376..521dbf80 100644 --- a/modules/mailu/cmd/automx/testdata/captured/03-thunderbird-on-autodiscover-name.body +++ b/modules/mailu/cmd/automx/testdata/captured/03-thunderbird-on-autodiscover-name.body @@ -1 +1 @@ -novox.benovox.benovox.be143STARTTLS%EMAILADDRESS%password-cleartextmail.novox.be587STARTTLS%EMAILADDRESS%password-cleartext \ No newline at end of file +node-c.benode-c.benode-c.be143STARTTLS%EMAILADDRESS%password-cleartextmail.node-c.be587STARTTLS%EMAILADDRESS%password-cleartext \ No newline at end of file diff --git a/modules/mailu/cmd/automx/testdata/captured/03-thunderbird-on-autodiscover-name.corrected.body b/modules/mailu/cmd/automx/testdata/captured/03-thunderbird-on-autodiscover-name.corrected.body index 0adc5c4c..ad24a7a9 100644 --- a/modules/mailu/cmd/automx/testdata/captured/03-thunderbird-on-autodiscover-name.corrected.body +++ b/modules/mailu/cmd/automx/testdata/captured/03-thunderbird-on-autodiscover-name.corrected.body @@ -1 +1 @@ -novox.benovox.benovox.bemail.novox.be143STARTTLS%EMAILADDRESS%password-cleartextmail.novox.be587STARTTLS%EMAILADDRESS%password-cleartext \ No newline at end of file +node-c.benode-c.benode-c.bemail.node-c.be143STARTTLS%EMAILADDRESS%password-cleartextmail.node-c.be587STARTTLS%EMAILADDRESS%password-cleartext \ No newline at end of file diff --git a/modules/mailu/cmd/automx/testdata/captured/03-thunderbird-on-autodiscover-name.request b/modules/mailu/cmd/automx/testdata/captured/03-thunderbird-on-autodiscover-name.request index 5b33fcce..db13436d 100644 --- a/modules/mailu/cmd/automx/testdata/captured/03-thunderbird-on-autodiscover-name.request +++ b/modules/mailu/cmd/automx/testdata/captured/03-thunderbird-on-autodiscover-name.request @@ -1,2 +1,2 @@ -GET https://autodiscover.novox.be/mail/config-v1.1.xml?emailaddress=jochen@novox.be +GET https://autodiscover.node-c.be/mail/config-v1.1.xml?emailaddress=jochen@node-c.be User-Agent: Thunderbird diff --git a/modules/mailu/cmd/automx/testdata/captured/04-thunderbird-unknown-domain.request b/modules/mailu/cmd/automx/testdata/captured/04-thunderbird-unknown-domain.request index d2459a88..f3da5866 100644 --- a/modules/mailu/cmd/automx/testdata/captured/04-thunderbird-unknown-domain.request +++ b/modules/mailu/cmd/automx/testdata/captured/04-thunderbird-unknown-domain.request @@ -1,2 +1,2 @@ -GET https://autoconfig.novox.be/mail/config-v1.1.xml?emailaddress=nobody@unknown.example +GET https://autoconfig.node-c.be/mail/config-v1.1.xml?emailaddress=nobody@unknown.example User-Agent: Thunderbird diff --git a/modules/mailu/cmd/automx/testdata/captured/05-thunderbird-missing-emailaddress.request b/modules/mailu/cmd/automx/testdata/captured/05-thunderbird-missing-emailaddress.request index 5d521f35..8b8fb6b0 100644 --- a/modules/mailu/cmd/automx/testdata/captured/05-thunderbird-missing-emailaddress.request +++ b/modules/mailu/cmd/automx/testdata/captured/05-thunderbird-missing-emailaddress.request @@ -1,2 +1,2 @@ -GET https://autoconfig.novox.be/mail/config-v1.1.xml +GET https://autoconfig.node-c.be/mail/config-v1.1.xml User-Agent: Thunderbird diff --git a/modules/mailu/cmd/automx/testdata/captured/06-autoconfig-root.request b/modules/mailu/cmd/automx/testdata/captured/06-autoconfig-root.request index 4dc45b54..35577694 100644 --- a/modules/mailu/cmd/automx/testdata/captured/06-autoconfig-root.request +++ b/modules/mailu/cmd/automx/testdata/captured/06-autoconfig-root.request @@ -1,2 +1,2 @@ -GET https://autoconfig.novox.be/ +GET https://autoconfig.node-c.be/ User-Agent: Mozilla/5.0 diff --git a/modules/mailu/cmd/automx/testdata/captured/07-wellknown-autoconfig-path.request b/modules/mailu/cmd/automx/testdata/captured/07-wellknown-autoconfig-path.request index d45d9935..a24d2125 100644 --- a/modules/mailu/cmd/automx/testdata/captured/07-wellknown-autoconfig-path.request +++ b/modules/mailu/cmd/automx/testdata/captured/07-wellknown-autoconfig-path.request @@ -1 +1 @@ -GET https://autoconfig.novox.be/.well-known/autoconfig/mail/config-v1.1.xml?emailaddress=jochen@novox.be +GET https://autoconfig.node-c.be/.well-known/autoconfig/mail/config-v1.1.xml?emailaddress=jochen@node-c.be diff --git a/modules/mailu/cmd/automx/testdata/captured/08-outlook-post-known-domain.request b/modules/mailu/cmd/automx/testdata/captured/08-outlook-post-known-domain.request index 258c92a6..5c1983c4 100644 --- a/modules/mailu/cmd/automx/testdata/captured/08-outlook-post-known-domain.request +++ b/modules/mailu/cmd/automx/testdata/captured/08-outlook-post-known-domain.request @@ -1,4 +1,4 @@ -POST https://autodiscover.novox.be/autodiscover/autodiscover.xml +POST https://autodiscover.node-c.be/autodiscover/autodiscover.xml User-Agent: Microsoft Office/16.0 (Windows NT 10.0; Microsoft Outlook 16.0.14326; Pro) Content-Type: text/xml Accept: */* @@ -6,7 +6,7 @@ Accept: */* - jochen@novox.be + jochen@node-c.be http://schemas.microsoft.com/exchange/autodiscover/outlook/responseschema/2006a diff --git a/modules/mailu/cmd/automx/testdata/captured/09-outlook-post-unknown-domain.request b/modules/mailu/cmd/automx/testdata/captured/09-outlook-post-unknown-domain.request index 990a009c..588a5777 100644 --- a/modules/mailu/cmd/automx/testdata/captured/09-outlook-post-unknown-domain.request +++ b/modules/mailu/cmd/automx/testdata/captured/09-outlook-post-unknown-domain.request @@ -1,4 +1,4 @@ -POST https://autodiscover.novox.be/autodiscover/autodiscover.xml +POST https://autodiscover.node-c.be/autodiscover/autodiscover.xml User-Agent: Microsoft Office/16.0 Content-Type: text/xml diff --git a/modules/mailu/cmd/automx/testdata/captured/10-outlook-post-malformed-body.request b/modules/mailu/cmd/automx/testdata/captured/10-outlook-post-malformed-body.request index 7467eeee..429c7cb8 100644 --- a/modules/mailu/cmd/automx/testdata/captured/10-outlook-post-malformed-body.request +++ b/modules/mailu/cmd/automx/testdata/captured/10-outlook-post-malformed-body.request @@ -1,4 +1,4 @@ -POST https://autodiscover.novox.be/autodiscover/autodiscover.xml +POST https://autodiscover.node-c.be/autodiscover/autodiscover.xml User-Agent: Microsoft Office/16.0 Content-Type: text/xml diff --git a/modules/mailu/cmd/automx/testdata/captured/11-outlook-post-missing-emailaddress.request b/modules/mailu/cmd/automx/testdata/captured/11-outlook-post-missing-emailaddress.request index abea016e..2b47b3aa 100644 --- a/modules/mailu/cmd/automx/testdata/captured/11-outlook-post-missing-emailaddress.request +++ b/modules/mailu/cmd/automx/testdata/captured/11-outlook-post-missing-emailaddress.request @@ -1,4 +1,4 @@ -POST https://autodiscover.novox.be/autodiscover/autodiscover.xml +POST https://autodiscover.node-c.be/autodiscover/autodiscover.xml User-Agent: Microsoft Office/16.0 Content-Type: text/xml diff --git a/modules/mailu/cmd/automx/testdata/captured/12-outlook-get-not-allowed.request b/modules/mailu/cmd/automx/testdata/captured/12-outlook-get-not-allowed.request index 11530419..c10f6124 100644 --- a/modules/mailu/cmd/automx/testdata/captured/12-outlook-get-not-allowed.request +++ b/modules/mailu/cmd/automx/testdata/captured/12-outlook-get-not-allowed.request @@ -1,2 +1,2 @@ -GET https://autodiscover.novox.be/autodiscover/autodiscover.xml +GET https://autodiscover.node-c.be/autodiscover/autodiscover.xml User-Agent: Microsoft Office/16.0 diff --git a/modules/mailu/cmd/automx/testdata/captured/13-outlook-post-capitalised-path.request b/modules/mailu/cmd/automx/testdata/captured/13-outlook-post-capitalised-path.request index ff129abe..40623338 100644 --- a/modules/mailu/cmd/automx/testdata/captured/13-outlook-post-capitalised-path.request +++ b/modules/mailu/cmd/automx/testdata/captured/13-outlook-post-capitalised-path.request @@ -1,6 +1,6 @@ -POST https://autodiscover.novox.be/Autodiscover/Autodiscover.xml +POST https://autodiscover.node-c.be/Autodiscover/Autodiscover.xml User-Agent: Microsoft Office/16.0 Content-Type: text/xml -jochen@novox.behttp://schemas.microsoft.com/exchange/autodiscover/outlook/responseschema/2006a +jochen@node-c.behttp://schemas.microsoft.com/exchange/autodiscover/outlook/responseschema/2006a diff --git a/modules/mailu/cmd/automx/testdata/captured/14-mobileconfig-no-slash.body b/modules/mailu/cmd/automx/testdata/captured/14-mobileconfig-no-slash.body index bc384fc9..2554bff8 100644 --- a/modules/mailu/cmd/automx/testdata/captured/14-mobileconfig-no-slash.body +++ b/modules/mailu/cmd/automx/testdata/captured/14-mobileconfig-no-slash.body @@ -2,4 +2,4 @@ Redirecting...

Redirecting...

-

You should be redirected automatically to the target URL: https://automx.novox.be/mobileconfig/?emailaddress=jochen@novox.be. If not, click the link. +

You should be redirected automatically to the target URL: https://automx.node-c.be/mobileconfig/?emailaddress=jochen@node-c.be. If not, click the link. diff --git a/modules/mailu/cmd/automx/testdata/captured/14-mobileconfig-no-slash.headers b/modules/mailu/cmd/automx/testdata/captured/14-mobileconfig-no-slash.headers index 75822817..a8f4e9c2 100644 --- a/modules/mailu/cmd/automx/testdata/captured/14-mobileconfig-no-slash.headers +++ b/modules/mailu/cmd/automx/testdata/captured/14-mobileconfig-no-slash.headers @@ -1,4 +1,4 @@ -Content-Length: 319 +Content-Length: 323 Content-Type: text/html; charset=utf-8 -Location: https://automx.novox.be/mobileconfig/?emailaddress=jochen@novox.be +Location: https://automx.node-c.be/mobileconfig/?emailaddress=jochen@node-c.be Server: Werkzeug/3.1.9 Python/3.9.5 diff --git a/modules/mailu/cmd/automx/testdata/captured/14-mobileconfig-no-slash.request b/modules/mailu/cmd/automx/testdata/captured/14-mobileconfig-no-slash.request index ee86c5ba..8a495267 100644 --- a/modules/mailu/cmd/automx/testdata/captured/14-mobileconfig-no-slash.request +++ b/modules/mailu/cmd/automx/testdata/captured/14-mobileconfig-no-slash.request @@ -1,3 +1,3 @@ -GET https://automx.novox.be/mobileconfig?emailaddress=jochen@novox.be +GET https://automx.node-c.be/mobileconfig?emailaddress=jochen@node-c.be User-Agent: Mozilla/5.0 (iPhone; CPU iPhone OS 17_0 like Mac OS X) Safari Accept: */* diff --git a/modules/mailu/cmd/automx/testdata/captured/15-mobileconfig-known-domain.request b/modules/mailu/cmd/automx/testdata/captured/15-mobileconfig-known-domain.request index 47197a20..4edbe6df 100644 --- a/modules/mailu/cmd/automx/testdata/captured/15-mobileconfig-known-domain.request +++ b/modules/mailu/cmd/automx/testdata/captured/15-mobileconfig-known-domain.request @@ -1,3 +1,3 @@ -GET https://automx.novox.be/mobileconfig/?emailaddress=jochen@novox.be +GET https://automx.node-c.be/mobileconfig/?emailaddress=jochen@node-c.be User-Agent: Mozilla/5.0 (iPhone; CPU iPhone OS 17_0 like Mac OS X) Safari Accept: */* diff --git a/modules/mailu/cmd/automx/testdata/captured/16-mobileconfig-unknown-domain.request b/modules/mailu/cmd/automx/testdata/captured/16-mobileconfig-unknown-domain.request index b38acb38..26bfdf3d 100644 --- a/modules/mailu/cmd/automx/testdata/captured/16-mobileconfig-unknown-domain.request +++ b/modules/mailu/cmd/automx/testdata/captured/16-mobileconfig-unknown-domain.request @@ -1,2 +1,2 @@ -GET https://automx.novox.be/mobileconfig/?emailaddress=nobody@unknown.example +GET https://automx.node-c.be/mobileconfig/?emailaddress=nobody@unknown.example User-Agent: Mozilla/5.0 (iPhone) diff --git a/modules/mailu/cmd/automx/testdata/captured/17-mobileconfig-missing-emailaddress.request b/modules/mailu/cmd/automx/testdata/captured/17-mobileconfig-missing-emailaddress.request index a7f84362..cc4f35b6 100644 --- a/modules/mailu/cmd/automx/testdata/captured/17-mobileconfig-missing-emailaddress.request +++ b/modules/mailu/cmd/automx/testdata/captured/17-mobileconfig-missing-emailaddress.request @@ -1,2 +1,2 @@ -GET https://automx.novox.be/mobileconfig/ +GET https://automx.node-c.be/mobileconfig/ User-Agent: Mozilla/5.0 (iPhone) diff --git a/modules/mailu/cmd/automx/testdata/captured/CAPTURED b/modules/mailu/cmd/automx/testdata/captured/CAPTURED index 01a9be83..f80f81f1 100644 --- a/modules/mailu/cmd/automx/testdata/captured/CAPTURED +++ b/modules/mailu/cmd/automx/testdata/captured/CAPTURED @@ -1,10 +1,10 @@ -What mailu's autoconfiguration module (automx2 2021.6, container mailu-automx on novox, Werkzeug/3.1.9 Python/3.9.5) +What mailu's autoconfiguration module (automx2 2021.6, container mailu-automx on node-c, Werkzeug/3.1.9 Python/3.9.5) answers to the requests mail clients make (R4d step AMX-1, issue 1630, ADR 0480). Captured 2026-10-21 between 13:58:25 and 13:58:52 (CEST; the Date headers said 11:58 GMT) with the mesh tool -shanks/netcheck.netcheck_request, called from shanks, through the names clients use (autoconfig.novox.be, -autodiscover.novox.be, automx.novox.be: HTTPS, the mesh's route), no ssh. A redirect is reported, never followed. -Mail domain served: novox.be. Mailbox used: jochen@novox.be; unknown domain: nobody@unknown.example. +node-d/netcheck.netcheck_request, called from node-d, through the names clients use (autoconfig.node-c.be, +autodiscover.node-c.be, automx.node-c.be: HTTPS, the mesh's route), no ssh. A redirect is reported, never followed. +Mail domain served: node-c.be. Mailbox used: jochen@node-c.be; unknown domain: nobody@unknown.example. Each capture is four files with the same stem: .request method and URL, then the request headers sent, then (after a blank line) the body sent @@ -24,7 +24,7 @@ A fixture is not the bytes on the wire in four ways (issue 1701): What the answers show (read, not guessed): - GET /mail/config-v1.1.xml?emailaddress=... answers 200 application/xml on all three names; same body on each. - The incoming (IMAP) server has an EMPTY hostname (), port 143, STARTTLS. The outgoing server is - mail.novox.be:587 STARTTLS. Cause (from reading the module, not from the database): automx/files/add-domains:35 + mail.node-c.be:587 STARTTLS. Cause (from reading the module, not from the database): automx/files/add-domains:35 reads AMX_IMAP_SERVER, files/mailu.env:58 sets AMX_IMAP_ADDRESS, so the IMAP name was never written. A client given this answer cannot find its IMAP server. - POST /autodiscover/autodiscover.xml with a valid request for the served domain answers 500 (the Outlook diff --git a/modules/mailu/cmd/automx/testdata/captured/DIFFERENCES b/modules/mailu/cmd/automx/testdata/captured/DIFFERENCES index 8274fdd9..f162a76c 100644 --- a/modules/mailu/cmd/automx/testdata/captured/DIFFERENCES +++ b/modules/mailu/cmd/automx/testdata/captured/DIFFERENCES @@ -6,7 +6,7 @@ whole list of where the two differ. server because its setup script read AMX_IMAP_SERVER, which mailu's environment does not set (it sets AMX_IMAP_ADDRESS). The program names it from AMX_IMAP_ADDRESS (and the port from AMX_IMAP_PORT). Fixtures 01, 02 and 03 each have a .corrected.body: the capture with replaced by - mail.novox.be and nothing else (a test checks that). Their Content-Length is that file's + mail.node-c.be and nothing else (a test checks that). Their Content-Length is that file's size, 634, not the captured 612. 2. The Server header. The capture has "Server: Werkzeug/3.1.9 Python/3.9.5". The program sends no Server header, and diff --git a/modules/minio/cmd/object-store/server_test.go b/modules/minio/cmd/object-store/server_test.go index 2f944a27..61795806 100644 --- a/modules/minio/cmd/object-store/server_test.go +++ b/modules/minio/cmd/object-store/server_test.go @@ -18,19 +18,19 @@ const grantFile = `{ "contributions": 1, "requirement": "s3-bucket", "given": [ - {"from": "brother", "node": "shanks", "as": "brother-key", + {"from": "brother", "node": "node-d", "as": "brother-key", "values": {"shares": [{"to": "seat:node-files", "methods": ["put"]}, {"to": "print-and-scan", "methods": ["get"]}]}, - "derived": {"bucket": "mesh-shanks-brother"}}, - {"from": "nextcloud", "node": "novox", "as": "nextcloud-key", "derived": {"bucket": "mesh-novox-nextcloud"}} + "derived": {"bucket": "mesh-node-d-brother"}}, + {"from": "nextcloud", "node": "node-c", "as": "nextcloud-key", "derived": {"bucket": "mesh-node-c-nextcloud"}} ] }` // The seats answer is the controller's (mesh-controller.seats read on 2026-10-21): seats[].holders[] of {node, module}, // and outside[] of {Claim, Node, Module}. const seatsAnswer = `{"answer": {"seats": [ - {"seat": "node-files", "scope": "node", "holders": [{"node": "g14", "module": "mesh-files"}, {"node": "shanks", "module": "mesh-files"}]}, - {"seat": "node-backup", "scope": "node", "holders": [{"node": "g14", "module": "restic"}]} - ], "outside": [{"Claim": "printer", "Scope": "mesh", "Node": "shanks", "Module": "brother", "Site": "home", "Kind": ""}]}}` + {"seat": "node-files", "scope": "node", "holders": [{"node": "node-b", "module": "mesh-files"}, {"node": "node-d", "module": "mesh-files"}]}, + {"seat": "node-backup", "scope": "node", "holders": [{"node": "node-b", "module": "restic"}]} + ], "outside": [{"Claim": "printer", "Scope": "mesh", "Node": "node-d", "Module": "brother", "Site": "home", "Kind": ""}]}}` type rig struct { s *server @@ -54,10 +54,10 @@ func newRig(t *testing.T) *rig { } return p } - // What the mesh renders from files/object-store.json for a store on novox.internal, port 20001. - cfg := write("object-store.json", `{"scheme":"http","at":"novox.internal","port":"20001","region":"eu-west"}`) - write("links/mesh-shanks-brother.secret", "brother-link-secret\n") - write("links/mesh-novox-nextcloud.secret", "nextcloud-link-secret\n") + // What the mesh renders from files/object-store.json for a store on node-c.internal, port 20001. + cfg := write("object-store.json", `{"scheme":"http","at":"node-c.internal","port":"20001","region":"eu-west"}`) + write("links/mesh-node-d-brother.secret", "brother-link-secret\n") + write("links/mesh-node-c-nextcloud.secret", "nextcloud-link-secret\n") grants := write("grants/mesh.json", grantFile) s, err := newServer(cfg, filepath.Join(dir, "links"), grants) if err != nil { @@ -96,16 +96,16 @@ func linkOf(t *testing.T, got any) *url.URL { // 1516/AC1: brother's own ask gets a link signed with the bucket's link key, for the store's host and port, 300 s. func TestLinkIsSignedWithTheBucketsLinkKey(t *testing.T) { r := newRig(t) - got, err := r.s.link("shanks.brother", ask("mesh-shanks-brother", "get", float64(300))) + got, err := r.s.link("node-d.brother", ask("mesh-node-d-brother", "get", float64(300))) if err != nil { t.Fatal(err) } u := linkOf(t, got) - if u.Host != "novox.internal:20001" || u.Scheme != "http" || u.Path != "/mesh-shanks-brother/doc.pdf" { + if u.Host != "node-c.internal:20001" || u.Scheme != "http" || u.Path != "/mesh-node-d-brother/doc.pdf" { t.Fatalf("link goes to %s", u) } q := u.Query() - if cred := q.Get("X-Amz-Credential"); !strings.HasPrefix(cred, linkKeyID("mesh-shanks-brother")+"/20261021/eu-west/s3/") { + if cred := q.Get("X-Amz-Credential"); !strings.HasPrefix(cred, linkKeyID("mesh-node-d-brother")+"/20261021/eu-west/s3/") { t.Fatalf("credential %q is not the bucket's link key", cred) } if strings.Contains(u.String(), "meshroot") { @@ -124,18 +124,18 @@ func TestLinkKeyIDMatchesTheProvisioners(t *testing.T) { } } -// 1516/AC2: a share to seat:node-files for put, mesh-files holding node-files on g14: put given, get refused naming the method. +// 1516/AC2: a share to seat:node-files for put, mesh-files holding node-files on node-b: put given, get refused naming the method. func TestSeatShareGivesTheHoldersTheSharedMethodOnly(t *testing.T) { r := newRig(t) - if _, err := r.s.link("g14.mesh-files", ask("mesh-shanks-brother", "put", nil)); err != nil { + if _, err := r.s.link("node-b.mesh-files", ask("mesh-node-d-brother", "put", nil)); err != nil { t.Fatalf("put: %v", err) } - _, err := r.s.link("g14.mesh-files", ask("mesh-shanks-brother", "get", nil)) + _, err := r.s.link("node-b.mesh-files", ask("mesh-node-d-brother", "get", nil)) if err == nil || !strings.Contains(err.Error(), "put, not get") { t.Fatalf("get was not refused naming the method: %v", err) } // A module share is judged by name alone. - if _, err := r.s.link("novox.print-and-scan", ask("mesh-shanks-brother", "get", nil)); err != nil { + if _, err := r.s.link("node-c.print-and-scan", ask("mesh-node-d-brother", "get", nil)); err != nil { t.Fatalf("print-and-scan get: %v", err) } } @@ -148,14 +148,14 @@ func TestRefusals(t *testing.T) { args map[string]any want string }{ - {"a stranger", "g14.restic", ask("mesh-shanks-brother", "get", nil), "not the bucket's consumer"}, - {"a seat it does not hold", "g14.restic", ask("mesh-shanks-brother", "put", nil), "not the bucket's consumer"}, - {"unproven", "unproven", ask("mesh-shanks-brother", "get", nil), "did not prove"}, - {"no grant", "shanks.brother", ask("no-such-bucket", "get", nil), "no grant names bucket"}, - {"seconds over 600", "shanks.brother", ask("mesh-shanks-brother", "get", float64(601)), "at most ten minutes"}, - {"seconds zero", "shanks.brother", ask("mesh-shanks-brother", "get", float64(0)), "outside 1 to 600"}, - {"method delete", "shanks.brother", ask("mesh-shanks-brother", "delete", nil), "not get or put"}, - {"another consumer's bucket", "shanks.brother", ask("mesh-novox-nextcloud", "get", nil), "not the bucket's consumer"}, + {"a stranger", "node-b.restic", ask("mesh-node-d-brother", "get", nil), "not the bucket's consumer"}, + {"a seat it does not hold", "node-b.restic", ask("mesh-node-d-brother", "put", nil), "not the bucket's consumer"}, + {"unproven", "unproven", ask("mesh-node-d-brother", "get", nil), "did not prove"}, + {"no grant", "node-d.brother", ask("no-such-bucket", "get", nil), "no grant names bucket"}, + {"seconds over 600", "node-d.brother", ask("mesh-node-d-brother", "get", float64(601)), "at most ten minutes"}, + {"seconds zero", "node-d.brother", ask("mesh-node-d-brother", "get", float64(0)), "outside 1 to 600"}, + {"method delete", "node-d.brother", ask("mesh-node-d-brother", "delete", nil), "not get or put"}, + {"another consumer's bucket", "node-d.brother", ask("mesh-node-c-nextcloud", "get", nil), "not the bucket's consumer"}, } for _, c := range cases { _, err := r.s.link(c.caller, c.args) @@ -170,14 +170,14 @@ func TestRefusals(t *testing.T) { func TestSeatsUnreadableAndCached(t *testing.T) { r := newRig(t) r.seatsErr = errors.New("the controller did not answer") - _, err := r.s.link("g14.mesh-files", ask("mesh-shanks-brother", "put", nil)) + _, err := r.s.link("node-b.mesh-files", ask("mesh-node-d-brother", "put", nil)) if err == nil || !strings.Contains(err.Error(), "the controller did not answer") || !strings.Contains(err.Error(), "node-files") { t.Fatalf("not refused naming why: %v", err) } r.seatsErr = nil put := func() { t.Helper() - if _, err := r.s.link("g14.mesh-files", ask("mesh-shanks-brother", "put", nil)); err != nil { + if _, err := r.s.link("node-b.mesh-files", ask("mesh-node-d-brother", "put", nil)); err != nil { t.Fatal(err) } } @@ -201,17 +201,17 @@ func TestSeatsUnreadableAndCached(t *testing.T) { // 1516/AC5: the grant file is read at each call. func TestGrantFileIsReadAtEachCall(t *testing.T) { r := newRig(t) - if _, err := r.s.link("novox.print-and-scan", ask("mesh-shanks-brother", "get", nil)); err != nil { + if _, err := r.s.link("node-c.print-and-scan", ask("mesh-node-d-brother", "get", nil)); err != nil { t.Fatal(err) } changed := strings.Replace(grantFile, `{"to": "print-and-scan", "methods": ["get"]}`, `{"to": "someone-else", "methods": ["get"]}`, 1) if err := os.WriteFile(r.s.receives, []byte(changed), 0o600); err != nil { t.Fatal(err) } - if _, err := r.s.link("novox.print-and-scan", ask("mesh-shanks-brother", "get", nil)); err == nil { + if _, err := r.s.link("node-c.print-and-scan", ask("mesh-node-d-brother", "get", nil)); err == nil { t.Fatal("the second call judged by the old shares") } - if _, err := r.s.link("novox.someone-else", ask("mesh-shanks-brother", "get", nil)); err != nil { + if _, err := r.s.link("node-c.someone-else", ask("mesh-node-d-brother", "get", nil)); err != nil { t.Fatal(err) } }