Skip to content

Commit

Permalink
Merge pull request #1 from arkavo-org/feat/fork-import
Browse files Browse the repository at this point in the history
feat(all): fork import path update
  • Loading branch information
arkavo-com authored Apr 6, 2024
2 parents 7cd4f26 + d453a98 commit 7539196
Show file tree
Hide file tree
Showing 95 changed files with 283 additions and 294 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/checks.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ jobs:
continue-on-error: true
with:
input: service
against: "https://github.com/opentdf/platform.git#branch=main,subdir=service"
against: "https://github.com/arkavo-org/opentdf-platform.git#branch=main,subdir=service"
- uses: actions/setup-go@0c52d547c9bc32b1aa3301fd7a9cb496313a4491
with:
go-version: "1.21.8"
Expand Down
18 changes: 6 additions & 12 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,10 +1,4 @@
# OpenTDF Enhancements POC

![CI](https://github.com/opentdf/platform/actions/workflows/checks.yaml/badge.svg?branch=main)

![lint](https://github.com/opentdf/platform/actions/workflows/lint-all.yaml/badge.svg?branch=main)

![Vulnerability Check](https://github.com/opentdf/platform/actions/workflows/vulnerability-check.yaml/badge.svg?branch=main)
# OpenTDF Platform (Fork of)

## Documentation

Expand Down Expand Up @@ -51,20 +45,20 @@ On macOS, these can be installed with [brew](https://docs.brew.sh/Installation)
> [!NOTE]
> Migrations are handled automatically by the server. This can be disabled via the config file, as
> needed. They can also be run manually using the `migrate` command
> (`make go.work`;`go run github.com/opentdf/platform/service migrate up`).
> (`make go.work`;`go run github.com/arkavo-org/opentdf-platform/service migrate up`).
1. `docker-compose up`
2. Create an OpenTDF config file: `opentdf.yaml`
1. The `opentdf-example.yaml` file is a good starting point, but you may need to modify it to match your environment.
2. The `opentdf-example-no-kas.yaml` file configures the platform to run insecurely without KAS and without endpoint auth.
3. Provision keycloak `go run github.com/opentdf/platform/service provision keycloak`
3. Provision keycloak `go run github.com/arkavo-org/opentdf-platform/service provision keycloak`
4. Configure KAS keys and your HSM with `.github/scripts/hsm-init-temporary-keys.sh`
5. Run the server `go run github.com/opentdf/platform/service start`
5. Run the server `go run github.com/arkavo-org/opentdf-platform/service start`
1. _Alt_ use the hot-reload development environment `air`
6. The server is now running on `localhost:8080` (or the port specified in the config file)

Note: support was added to provision a set of fixture data into the database.
Run `go run github.com/opentdf/platform/service provision fixtures -h` for more information.
Run `go run github.com/arkavo-org/opentdf-platform/service provision fixtures -h` for more information.

### Generation

Expand Down Expand Up @@ -117,4 +111,4 @@ To see how to generate key pairs that KAS can use, review the [the temp keys ini
### Policy

The policy service is responsible for managing policy configurations. It provides a gRPC API for
creating, updating, and deleting policy configurations. [Docs](https://github.com/opentdf/platform/tree/main/docs)
creating, updating, and deleting policy configurations. [Docs](https://github.com/arkavo-org/opentdf-platform/tree/main/docs)
2 changes: 1 addition & 1 deletion buf.gen.grpc.docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: v1
managed:
enabled: true
go_package_prefix:
default: github.com/opentdf/platform/protocol/go
default: github.com/arkavo-org/opentdf-platform/protocol/go
except:
- buf.build/bufbuild/protovalidate
- buf.build/googleapis/googleapis
Expand Down
2 changes: 1 addition & 1 deletion buf.gen.openapi.docs.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: v1
managed:
enabled: true
go_package_prefix:
default: github.com/opentdf/platform/protocol/go
default: github.com/arkavo-org/opentdf-platform/protocol/go
except:
- buf.build/bufbuild/protovalidate
- buf.build/googleapis/googleapis
Expand Down
2 changes: 1 addition & 1 deletion buf.gen.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: v1
managed:
enabled: true
go_package_prefix:
default: github.com/opentdf/platform/protocol/go
default: github.com/arkavo-org/opentdf-platform/protocol/go
except:
- buf.build/bufbuild/protovalidate
- buf.build/googleapis/googleapis
Expand Down
8 changes: 4 additions & 4 deletions examples/cmd/attributes.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,10 +5,10 @@ import (
"fmt"
"log/slog"

"github.com/opentdf/platform/protocol/go/policy"
"github.com/opentdf/platform/protocol/go/policy/attributes"
"github.com/opentdf/platform/protocol/go/policy/namespaces"
"github.com/opentdf/platform/sdk"
"github.com/arkavo-org/opentdf-platform/protocol/go/policy"
"github.com/arkavo-org/opentdf-platform/protocol/go/policy/attributes"
"github.com/arkavo-org/opentdf-platform/protocol/go/policy/namespaces"
"github.com/arkavo-org/opentdf-platform/sdk"
"github.com/spf13/cobra"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/status"
Expand Down
6 changes: 3 additions & 3 deletions examples/cmd/authorization.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,9 @@ import (
"fmt"
"log/slog"

"github.com/opentdf/platform/protocol/go/authorization"
"github.com/opentdf/platform/protocol/go/policy"
"github.com/opentdf/platform/sdk"
"github.com/arkavo-org/opentdf-platform/protocol/go/authorization"
"github.com/arkavo-org/opentdf-platform/protocol/go/policy"
"github.com/arkavo-org/opentdf-platform/sdk"
"github.com/spf13/cobra"
"google.golang.org/protobuf/encoding/protojson"
)
Expand Down
2 changes: 1 addition & 1 deletion examples/cmd/decrypt.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ import (
"os"
"strings"

"github.com/opentdf/platform/sdk"
"github.com/arkavo-org/opentdf-platform/sdk"
"github.com/spf13/cobra"
)

Expand Down
2 changes: 1 addition & 1 deletion examples/cmd/encrypt.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import (
"os"
"strings"

"github.com/opentdf/platform/sdk"
"github.com/arkavo-org/opentdf-platform/sdk"
"github.com/spf13/cobra"
)

Expand Down
13 changes: 5 additions & 8 deletions examples/go.mod
Original file line number Diff line number Diff line change
@@ -1,19 +1,17 @@
module github.com/opentdf/platform/examples
module github.com/arkavo-org/opentdf-platform/examples

go 1.21.8
go 1.22.2

require (
github.com/opentdf/platform/protocol/go v0.0.0-00010101000000-000000000000
github.com/opentdf/platform/sdk v0.0.0-00010101000000-000000000000
github.com/spf13/cobra v1.8.0
google.golang.org/grpc v1.62.1
google.golang.org/protobuf v1.33.0
)

replace (
github.com/opentdf/platform/lib/ocrypto => ../lib/ocrypto
github.com/opentdf/platform/protocol/go => ../protocol/go
github.com/opentdf/platform/sdk => ../sdk
github.com/arkavo-org/opentdf-platform/lib/ocrypto => ../lib/ocrypto
github.com/arkavo-org/opentdf-platform/protocol/go => ../protocol/go
github.com/arkavo-org/opentdf-platform/sdk => ../sdk
)

require (
Expand All @@ -32,7 +30,6 @@ require (
github.com/lestrrat-go/iter v1.0.2 // indirect
github.com/lestrrat-go/jwx/v2 v2.0.21 // indirect
github.com/lestrrat-go/option v1.0.1 // indirect
github.com/opentdf/platform/lib/ocrypto v0.0.0-00010101000000-000000000000 // indirect
github.com/rogpeppe/go-internal v1.12.0 // indirect
github.com/russross/blackfriday/v2 v2.1.0 // indirect
github.com/segmentio/asm v1.2.0 // indirect
Expand Down
2 changes: 1 addition & 1 deletion examples/main.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package main

import (
"github.com/opentdf/platform/examples/cmd"
"github.com/arkavo-org/opentdf-platform/examples/cmd"
)

func main() {
Expand Down
4 changes: 2 additions & 2 deletions lib/ocrypto/go.mod
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module github.com/opentdf/platform/lib/ocrypto
module github.com/arkavo-org/opentdf-platform/lib/ocrypto

go 1.21.8
go 1.22.2
2 changes: 1 addition & 1 deletion protocol/go/authorization/authorization.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions protocol/go/go.mod

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion protocol/go/kasregistry/key_access_server_registry.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions protocol/go/policy/attributes/attributes.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions protocol/go/policy/namespaces/namespaces.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions protocol/go/policy/objects.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions protocol/go/policy/resourcemapping/resource_mapping.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions protocol/go/policy/subjectmapping/subject_mapping.pb.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion sdk/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import bytes
import io
import os
import strings
import "github.com/opentdf/platform/sdk"
import "github.com/arkavo-org/opentdf-platform/sdk"


func main() {
Expand Down
2 changes: 1 addition & 1 deletion sdk/auth/token_adding_interceptor_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -13,11 +13,11 @@ import (
"slices"
"testing"

"github.com/arkavo-org/opentdf-platform/protocol/go/kas"
"github.com/lestrrat-go/jwx/v2/jwa"
"github.com/lestrrat-go/jwx/v2/jwk"
"github.com/lestrrat-go/jwx/v2/jws"
"github.com/lestrrat-go/jwx/v2/jwt"
"github.com/opentdf/platform/protocol/go/kas"
"google.golang.org/grpc"
"google.golang.org/grpc/codes"
"google.golang.org/grpc/credentials/insecure"
Expand Down
2 changes: 1 addition & 1 deletion sdk/auth_config.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ import (
"strings"
"time"

"github.com/arkavo-org/opentdf-platform/lib/ocrypto"
"github.com/golang-jwt/jwt/v4"
"github.com/opentdf/platform/lib/ocrypto"
)

type AuthConfig struct {
Expand Down
10 changes: 4 additions & 6 deletions sdk/go.mod
Original file line number Diff line number Diff line change
@@ -1,23 +1,21 @@
module github.com/opentdf/platform/sdk
module github.com/arkavo-org/opentdf-platform/sdk

go 1.21.8
go 1.22.2

require (
github.com/docker/go-connections v0.5.0
github.com/golang-jwt/jwt/v4 v4.5.0
github.com/google/uuid v1.6.0
github.com/lestrrat-go/jwx/v2 v2.0.21
github.com/opentdf/platform/lib/ocrypto v0.0.0-00010101000000-000000000000
github.com/opentdf/platform/protocol/go v0.0.0-00010101000000-000000000000
github.com/stretchr/testify v1.9.0
github.com/testcontainers/testcontainers-go v0.28.0
google.golang.org/grpc v1.62.1
google.golang.org/protobuf v1.33.0
)

replace (
github.com/opentdf/platform/lib/ocrypto => ../lib/ocrypto
github.com/opentdf/platform/protocol/go => ../protocol/go
github.com/arkavo-org/opentdf-platform/lib/ocrypto => ../lib/ocrypto
github.com/arkavo-org/opentdf-platform/protocol/go => ../protocol/go
)

require (
Expand Down
6 changes: 3 additions & 3 deletions sdk/idp_access_token_source.go
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,11 @@ import (
"strings"
"sync"

"github.com/arkavo-org/opentdf-platform/lib/ocrypto"
"github.com/arkavo-org/opentdf-platform/sdk/auth"
"github.com/arkavo-org/opentdf-platform/sdk/internal/oauth"
"github.com/lestrrat-go/jwx/v2/jwa"
"github.com/lestrrat-go/jwx/v2/jwk"
"github.com/opentdf/platform/lib/ocrypto"
"github.com/opentdf/platform/sdk/auth"
"github.com/opentdf/platform/sdk/internal/oauth"
)

const (
Expand Down
6 changes: 3 additions & 3 deletions sdk/kas_client.go
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ import (
"net/url"
"time"

"github.com/arkavo-org/opentdf-platform/lib/ocrypto"
"github.com/arkavo-org/opentdf-platform/protocol/go/kas"
"github.com/arkavo-org/opentdf-platform/sdk/auth"
"github.com/lestrrat-go/jwx/v2/jwk"
"github.com/lestrrat-go/jwx/v2/jwt"
"github.com/opentdf/platform/lib/ocrypto"
"github.com/opentdf/platform/protocol/go/kas"
"github.com/opentdf/platform/sdk/auth"
"google.golang.org/grpc"
)

Expand Down
4 changes: 2 additions & 2 deletions sdk/kas_client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@ import (

"google.golang.org/grpc"

"github.com/arkavo-org/opentdf-platform/lib/ocrypto"
"github.com/arkavo-org/opentdf-platform/sdk/auth"
"github.com/lestrrat-go/jwx/v2/jwa"
"github.com/lestrrat-go/jwx/v2/jwk"
"github.com/lestrrat-go/jwx/v2/jwt"
"github.com/opentdf/platform/lib/ocrypto"
"github.com/opentdf/platform/sdk/auth"
)

type FakeAccessTokenSource struct {
Expand Down
2 changes: 1 addition & 1 deletion sdk/options.go
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package sdk

import (
"github.com/opentdf/platform/sdk/internal/oauth"
"github.com/arkavo-org/opentdf-platform/sdk/internal/oauth"
"google.golang.org/grpc"
"google.golang.org/grpc/credentials/insecure"
)
Expand Down
14 changes: 7 additions & 7 deletions sdk/sdk.go
Original file line number Diff line number Diff line change
Expand Up @@ -5,13 +5,13 @@ import (
"errors"
"log/slog"

"github.com/opentdf/platform/protocol/go/authorization"
"github.com/opentdf/platform/protocol/go/kasregistry"
"github.com/opentdf/platform/protocol/go/policy/attributes"
"github.com/opentdf/platform/protocol/go/policy/namespaces"
"github.com/opentdf/platform/protocol/go/policy/resourcemapping"
"github.com/opentdf/platform/protocol/go/policy/subjectmapping"
"github.com/opentdf/platform/sdk/auth"
"github.com/arkavo-org/opentdf-platform/protocol/go/authorization"
"github.com/arkavo-org/opentdf-platform/protocol/go/kasregistry"
"github.com/arkavo-org/opentdf-platform/protocol/go/policy/attributes"
"github.com/arkavo-org/opentdf-platform/protocol/go/policy/namespaces"
"github.com/arkavo-org/opentdf-platform/protocol/go/policy/resourcemapping"
"github.com/arkavo-org/opentdf-platform/protocol/go/policy/subjectmapping"
"github.com/arkavo-org/opentdf-platform/sdk/auth"
"google.golang.org/grpc"
"google.golang.org/grpc/credentials"
)
Expand Down
Loading

0 comments on commit 7539196

Please sign in to comment.