Home > Backend Development > Golang > What is the private key in Oracle Object Storage?

What is the private key in Oracle Object Storage?

WBOY
Release: 2024-02-12 18:03:05
forward
1233 people have browsed it

What is the private key in Oracle Object Storage?

Question content

c, clerr := objectstorage.NewObjectStorageClientWithConfigurationProvider(common.NewRawConfigurationProvider(
    "ocid1.tenancy.oc1..aaaaaaa5jo3pz1alm1o45rzx1ucaab4njxbwaqqbc7ld3l6biayjaert5la",
    "ocid1.user.oc1..aaaaaaaauax5bo2gg3az46h53467u57ue86rk9h2wax8w7zzamxgwvsi34ja",
    "ap-seoul-1",
    "98:bc:6b:13:c1:64:ds:8b:9c:15:11:d2:8d:e5:92:db",
    
))
Copy after login

I'm trying to use oracle object storage, I checked the official manual, but there are some things I don't understand. As mentioned above, I need the privatekey and pricatekeypassphrase parameters, but I don't know where to get them. Is there any detailed explanation or example?

What I want is to upload the file to storage. Where can I get the key I need on the Oracle console page? Please give me some suggestions

Solution

config, err := common.ConfigurationProviderFromFile("./config", "")
    if err != nil {
        t.Error(err.Error())
    }
    c, err := objectstorage.NewObjectStorageClientWithConfigurationProvider(config)
    if err != nil {
        t.Error(err.Error())
    }
Copy after login

https://cloud.oracle.com/identity/domains/myprofile/api-key

I generated a key on this page, put it into my project and using the code above I was able to get started with no issues.

The above is the detailed content of What is the private key in Oracle Object Storage?. For more information, please follow other related articles on the PHP Chinese website!

source:stackoverflow.com
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template