Skip to content

Commit

Permalink
Add support for WASI port (google#1089)
Browse files Browse the repository at this point in the history
Fix building when the new `wasip1` port is being used.
This is a new target that will be introduced by go 1.21.

For more details golang/go#58141

Signed-off-by: Flavio Castelli <fcastelli@suse.com>
  • Loading branch information
flavio authored and breadyzhang committed Jun 2, 2023
1 parent 8b54358 commit d1de437
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 0 deletions.
3 changes: 3 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,9 @@

## HEAD

### Add support for WASI port
* Add build tags for wasip1 GOOS

### Add support for IBM Z operating system z/OS
* Add build tags for zos

Expand Down
19 changes: 19 additions & 0 deletions x509/root_wasip1.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
// Copyright 2018 The Go Authors. All rights reserved.
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

//go:build wasip1
// +build wasip1

package x509

// Possible certificate files; stop after finding one.
var certFiles = []string{}

func loadSystemRoots() (*CertPool, error) {
return NewCertPool(), nil
}

func (c *Certificate) systemVerify(opts *VerifyOptions) (chains [][]*Certificate, err error) {
return nil, nil
}

0 comments on commit d1de437

Please sign in to comment.