15
votes
Require inline action be sent by contract, and not account
UPDATE: This is the code I used to experiment with all combinations of permissions I could come up with: https://github.com/andresberrios/permissions_test
After a lot of experimentation, I finally ...
4
votes
Accepted
"dice" contract "withdraw" action problem
as explained in the message,
you need to add 'eosio.code' permission to dice@active
cleos set account permission dice active '{"threshold": 1,"keys": [{"key": "...
4
votes
Accepted
Are inline actions asynchronous?
Yes, both inline actions and deferred actions are asynchronous.
Which seems to be synchronous, so can we not assume synchronous behaviour(result is returned by the function call) for inline actions?
...
3
votes
Require inline action be sent by contract, and not account
This seems to work for me:
$ mkdir -p project/sender
$ mkdir project/recipient
$ touch project/sender/sender.cpp
$ touch project/recipient/recipient.cpp
sender.cpp
#include<eosiolib/eosio.hpp>...
3
votes
Can we get all the actions from all blocks?
You can get the inline actions in get_actions RPC History API endpoint or inside the details of a transaction using also the RPC API get_transaction.
So that's exactly what I'm doing in that eos-node-...
2
votes
require_auth differs from the auth check of INLINE_ACTION_SENDER but how?
From an answer by Todd Fleming on the EOS Developers Telegram channel:
If user A authorizes an action sent to contract B then that does not imply B can send an action to contract C with A's ...
2
votes
What is the difference between a method call and the use of SEND_INLINE_ACTION?
You can call any function of a smart contract from within the smart contract, however only functions labelled as actions can be called from outside of the smart contract.
So if you have a function in ...
1
vote
Accepted
Purpose of max_inline_action_size?
max_inline_action_size is one of a few blockchain_paramaters allowing to protect the network. Unlimited inline_action_size is a potential attack-vector and could be used by malicious actors to harm ...
1
vote
Accepted
Calling external action with 'action_wrapper' and 'action'
The results of both cases are identical, but action_wrapper provides compile-time type check. If you pass invalid parameters, you will fail to build your contract.
You don't need to include the header ...
1
vote
Accepted
How can multisig trigger an action in contract other than eosio.token contract?
You need to pass partner2 transaction auth in contract action data inorder to execute , not partner1's
{ "timestamp" :12345567, "author" : "partner2",....}
cleos multisig propose testfin '[{"actor"...
1
vote
Accepted
Are inline actions are executed in a separate transaction?
Inline actions are part of the same transaction, but their authorizations are separate. This limits abuse. e.g. if I send a playwith action to a crypto pet, the pet's contract can't unilaterally take ...
1
vote
Accepted
Contract A makes an inline call to contract B. How can B determine that A is the one making the call?
In Dawn 4.0 at least, when A calls B it does so with an authorization that is specific to itself (generally, c[email protected]). B can check the authorization.
1
vote
How to set up chain of permission levels for a user?
It seems hard to find an example that can answer all your questions.
Below is an example of sending an inline action without permission. You can learn a lot by reading this article.
https://trybe....
Only top scored, non community-wiki answers of a minimum length are eligible
Related Tags
inline-action × 23smart-contract × 13
eosio-code × 6
transactions × 4
action × 4
permissions × 4
eosio.token × 3
testnet × 2
blocks × 2
cleos × 1
multi-index × 1
tokens × 1
transfer × 1
authorization × 1
balances × 1
c# × 1
notification × 1
msig × 1