Sign in

Search issue titles and bodies, change requests and comments. Private repositories you cannot read are not included.

vole
Clone

Read only, no credentials:

https://rodent.software/vole.git

Write over SSH with a registered key:

git clone ssh://git@rodent.software:2222/vole.git

A free and open-source forge that lives in your Git repo.

Add automatic HTTPS with ACME

642e599466fe4f5066afdc9a24775694a52c9749 · Keenan Nemetz · 15d ago · parent 91e6a33a

forge/repo/repo_test.go +30

@@ -8,6 +8,7 @@ import (
8 8 "os"
9 9 "path/filepath"
10 10 "testing"
11 "time"
11 12
12 13 "github.com/rodent-software/vole/core/git"
13 14 "github.com/rodent-software/vole/forge/access"
@@ -169,3 +170,32 @@ func TestDescriptionWritesAndClears(t *testing.T) {
169 170 t.Fatalf("cleared description came back as %q", reopened.Description)
170 171 }
171 172 }
173
174 // Public is the other cheap question host policy asks: does this repository have
175 // an anonymous reader role? Private repository names must not reach a public
176 // certificate log.
177 func TestPublicRepositoriesAreTheOnlySitesEligibleForCertificates(t *testing.T) {
178 t.Parallel()
179 st, acls := withACLs(t)
180 if st.Public("missing") {
181 t.Fatal("a missing repository is public")
182 }
183 m, err := st.Create("demo", "01M5OWNER0000000000000000A", "")
184 if err != nil {
185 t.Fatal(err)
186 }
187 if st.Public("demo") {
188 t.Fatal("a new repository with no default role is public")
189 }
190 acl, err := m.ACL()
191 if err != nil {
192 t.Fatal(err)
193 }
194 acl.Default = "read"
195 if err := acls.Set(m.ID, acl, "01M5OWNER0000000000000000A", time.Now()); err != nil {
196 t.Fatal(err)
197 }
198 if !st.Public("demo") {
199 t.Fatal("a repository readable by default is not public")
200 }
201 }