New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

caos-set-code

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

caos-set-code

Flow SDK Stored Interaction - Set Account Code

latest
npmnpm
Version
0.0.3
Version published
Maintainers
1
Created
Source

@onflow/six-set-code

Stored Interaction for setting an Accounts Code on Flow

Status

  • Last Updated: August 31 2020
  • Stable: No
  • Risk of Breaking Change: Very High

Known Upcoming Changes:

  • Potential changes to all aspects of Stored Interactions

Install

npm install @onflow/six-set-code

Usage:

import * as fcl from "@onflow/fcl"
import { template as setCode } from "@onflow/six-set-code"

fcl.config().put("accessNode", "http://localhost:8080");

const response = await fcl.send([
    setCode({
        proposer: fcl.currentUser().authorization,
        authorization: fcl.currentUser().authorization,     
        payer: fcl.currentUser().authorization,             
        code: "my-cadence-code",                            // Cadence code as a utf8 encoded string.
    })
])

Hashing

Hashing Code:

    console.log(crypto.createHash('sha256').update(CODE, 'utf8').digest('hex'))

FAQs

Package last updated on 29 Mar 2021

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts