Skip to main content
deleted 103 characters in body
Source Link
cmadh
  • 1.9k
  • 3
  • 10
  • 29

Because the other answer seems not to be an acceptable solution for the problem - here another one:

The above case works if you do it like the following:

void multiauth(name user) {

   if (user == name("walletxxxxxx") || user == name("walletzzzzzz"))
   {
     require_auth(user);
   }
   else
   {
     require_auth(_self);
   }
}

But that's definitely not state of the art to grant permissions for execution of actions to specific accounts on eosio.

The name 'multiauth' itself says permissions should be granted to multiple users, a feature typicalother blockchains lackslack of. And eosio's solution is the inbuild permission system.

Because the other answer seems not to be an acceptable solution for the problem - here another one:

The above case works if you do it like the following:

void multiauth(name user) {

   if (user == name("walletxxxxxx") || user == name("walletzzzzzz"))
   {
     require_auth(user);
   }
   else
   {
     require_auth(_self);
   }
}

But that's definitely not state of the art to grant permissions for execution of actions to specific accounts on eosio.

The name 'multiauth' itself says permissions should be granted to multiple users, a feature typical blockchains lacks of. And eosio's solution is the inbuild permission system.

The above case works if you do it like the following:

void multiauth(name user) {

   if (user == name("walletxxxxxx") || user == name("walletzzzzzz"))
   {
     require_auth(user);
   }
   else
   {
     require_auth(_self);
   }
}

But that's definitely not state of the art to grant permissions for execution of actions to specific accounts on eosio.

The name 'multiauth' itself says permissions should be granted to multiple users, a feature other blockchains lack of. And eosio's solution is the inbuild permission system.

Source Link
cmadh
  • 1.9k
  • 3
  • 10
  • 29

Because the other answer seems not to be an acceptable solution for the problem - here another one:

The above case works if you do it like the following:

void multiauth(name user) {

   if (user == name("walletxxxxxx") || user == name("walletzzzzzz"))
   {
     require_auth(user);
   }
   else
   {
     require_auth(_self);
   }
}

But that's definitely not state of the art to grant permissions for execution of actions to specific accounts on eosio.

The name 'multiauth' itself says permissions should be granted to multiple users, a feature typical blockchains lacks of. And eosio's solution is the inbuild permission system.