eth以太坊yam || trx波场yam农场合约源码开发

矫情吗;* 2022-12-06 12:41 182阅读 0赞

以太坊农场合约或波场农场合约或抵押挖矿合约源码开发

yam介绍

官网地址:http://yam.finance/

联系开发者:见页脚

协议书

Yam是一个实验性协议,建立在可编程货币和治理方面最激动人心的创新之上。它由一组DeFi本地人构建,旨在创建:

•有弹性的供应,以寻求最终的价格稳定
•可管理的国库券,以进一步支持稳定
•完全的链上治理,以实现从第一天开始的分散控制和发展
•公平的分配机制,激励关键的社区成员积极掌握治理

YAM的核心是一种弹性的供应加密货币,它会根据市场情况扩展和收缩其供应,最初的目标是每YAM 1美元。这种稳定机制包括对现有弹性供应模型(例如Ampleforth)的一个关键补充:每次供应扩展的一部分都用于购买yCurve(高收益美元计价的稳定币)并将其添加到Yam国库中,该库由Yam控制社区治理。

我们将Yam构建为最低可行的货币实验,并且在启动时,YAM令牌中的值为零。部署后,它完全取决于YAM持有者来确定其价值和未来发展。我们采用了化合物治理模块的分支,它将确保对Yam协议的所有更新都是通过社区投票完全在链上进行的。

审核

没有。贡献者已尽最大努力确保这些合同的安全性,但不做任何保证。仅通过几双眼睛就可以对其进行检查。存在错误的可能性(而不仅仅是可能性)。也就是说,对放样/分发合同所做的更改很小,已通过SNX,YFI和YFI派生协议使数亿亿美元流经它们。储备合同也过于简单。我们首先将抵押资产的安全放在首位。

原始开发人员鼓励治理以资助漏洞赏金/安全审核

代币本身主要基于经过审核的COMP和Ampleforth-但我们进行了重要改动。

rebaser可能还存在错误-但已在多种情况下进行了测试。它仅限于调用rebase函数以增强安全性的外部拥有的帐户(EOA)。SafeMath随处可见。

如果您对这些披露不满意,请不要抵押或持有YAM。如果社区投票支持审核,或者社区获得了审核的资格,则不会假设原始开发人员将在周围实施修补程序,并且完全由他们自己决定。

代币

核心YAM令牌使用yCRV作为储备货币,大约是1美元钉。每次供应扩展(称为膨胀基础)时,都会铸造一部分代币并用于建立金库。然后,该国库通过治理完全由YAM持有人所有。

分配

YAM的精神不是分配资金给创始团队,而是按照YFI的精神进行分配:没有预谋,没有创始人股份,没有风投利益-只是机会均等的股权分配,以吸引广泛且视野一致的社区指导协议和令牌的未来。

YAM的初始分配将在八个权益池中平均分配:WETH,YFI,MKR,LEND,LINK,SNX,COMP和ETH / AMPL Uniswap v2 LP令牌。选择这些库的目的是为了覆盖整个DeFi社区以及特定社区,这些社区对主动治理和对复杂代币学的理解得到了公认的承诺。

在启动初始分配池之后,将通过YAM / yCRV Uniswap池激发第二次分配浪潮。该池将使Uniswap的基于TWAP的oracle提供必要的输入作为基础计算的基础,并为基础提供流动性,以购买yCurve的国库券。

部分源码:

  1. /**
  2. *Submitted for verification at Etherscan.io on 2020-07-17
  3. */
  4. /*
  5. ____ __ __ __ _
  6. / __/__ __ ___ / /_ / / ___ / /_ (_)__ __
  7. _\ \ / // // _ \/ __// _ \/ -_)/ __// / \ \ /
  8. /___/ \_, //_//_/\__//_//_/\__/ \__//_/ /_\_\
  9. /___/
  10. * Synthetix: YAMRewards.sol
  11. *
  12. * Docs: https://docs.synthetix.io/
  13. *
  14. *
  15. * MIT License
  16. * ===========
  17. *
  18. * Copyright (c) 2020 Synthetix
  19. *
  20. * Permission is hereby granted, free of charge, to any person obtaining a copy
  21. * of this software and associated documentation files (the "Software"), to deal
  22. * in the Software without restriction, including without limitation the rights
  23. * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
  24. * copies of the Software, and to permit persons to whom the Software is
  25. * furnished to do so, subject to the following conditions:
  26. *
  27. * The above copyright notice and this permission notice shall be included in all
  28. * copies or substantial portions of the Software.
  29. *
  30. * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
  31. * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
  32. * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
  33. * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
  34. * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  35. * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  36. */
  37. // File: @openzeppelin/contracts/math/Math.sol
  38. pragma solidity ^0.5.0;
  39. /**
  40. * @dev Standard math utilities missing in the Solidity language.
  41. */
  42. library Math {
  43. /**
  44. * @dev Returns the largest of two numbers.
  45. */
  46. function max(uint256 a, uint256 b) internal pure returns (uint256) {
  47. return a >= b ? a : b;
  48. }
  49. /**
  50. * @dev Returns the smallest of two numbers.
  51. */
  52. function min(uint256 a, uint256 b) internal pure returns (uint256) {
  53. return a < b ? a : b;
  54. }
  55. /**
  56. * @dev Returns the average of two numbers. The result is rounded towards
  57. * zero.
  58. */
  59. function average(uint256 a, uint256 b) internal pure returns (uint256) {
  60. // (a + b) / 2 can overflow, so we distribute
  61. return (a / 2) + (b / 2) + ((a % 2 + b % 2) / 2);
  62. }
  63. }
  64. // File: @openzeppelin/contracts/math/SafeMath.sol
  65. pragma solidity ^0.5.0;
  66. /**
  67. * @dev Wrappers over Solidity's arithmetic operations with added overflow
  68. * checks.
  69. *
  70. * Arithmetic operations in Solidity wrap on overflow. This can easily result
  71. * in bugs, because programmers usually assume that an overflow raises an
  72. * error, which is the standard behavior in high level programming languages.
  73. * `SafeMath` restores this intuition by reverting the transaction when an
  74. * operation overflows.
  75. *
  76. * Using this library instead of the unchecked operations eliminates an entire
  77. * class of bugs, so it's recommended to use it always.
  78. */
  79. library SafeMath {
  80. /**
  81. * @dev Returns the addition of two unsigned integers, reverting on
  82. * overflow.
  83. *
  84. * Counterpart to Solidity's `+` operator.
  85. *
  86. * Requirements:
  87. * - Addition cannot overflow.
  88. */
  89. function add(uint256 a, uint256 b) internal pure returns (uint256) {
  90. uint256 c = a + b;
  91. require(c >= a, "SafeMath: addition overflow");
  92. return c;
  93. }
  94. /**
  95. * @dev Returns the subtraction of two unsigned integers, reverting on
  96. * overflow (when the result is negative).
  97. *
  98. * Counterpart to Solidity's `-` operator.
  99. *
  100. * Requirements:
  101. * - Subtraction cannot overflow.
  102. */
  103. function sub(uint256 a, uint256 b) internal pure returns (uint256) {
  104. return sub(a, b, "SafeMath: subtraction overflow");
  105. }
  106. /**
  107. * @dev Returns the subtraction of two unsigned integers, reverting with custom message on
  108. * overflow (when the result is negative).
  109. *
  110. * Counterpart to Solidity's `-` operator.
  111. *
  112. * Requirements:
  113. * - Subtraction cannot overflow.
  114. *
  115. * _Available since v2.4.0._
  116. */
  117. function sub(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
  118. require(b <= a, errorMessage);
  119. uint256 c = a - b;
  120. return c;
  121. }
  122. /**
  123. * @dev Returns the multiplication of two unsigned integers, reverting on
  124. * overflow.
  125. *
  126. * Counterpart to Solidity's `*` operator.
  127. *
  128. * Requirements:
  129. * - Multiplication cannot overflow.
  130. */
  131. function mul(uint256 a, uint256 b) internal pure returns (uint256) {
  132. // Gas optimization: this is cheaper than requiring 'a' not being zero, but the
  133. // benefit is lost if 'b' is also tested.
  134. // See: https://github.com/OpenZeppelin/openzeppelin-contracts/pull/522
  135. if (a == 0) {
  136. return 0;
  137. }
  138. uint256 c = a * b;
  139. require(c / a == b, "SafeMath: multiplication overflow");
  140. return c;
  141. }
  142. /**
  143. * @dev Returns the integer division of two unsigned integers. Reverts on
  144. * division by zero. The result is rounded towards zero.
  145. *
  146. * Counterpart to Solidity's `/` operator. Note: this function uses a
  147. * `revert` opcode (which leaves remaining gas untouched) while Solidity
  148. * uses an invalid opcode to revert (consuming all remaining gas).
  149. *
  150. * Requirements:
  151. * - The divisor cannot be zero.
  152. */
  153. function div(uint256 a, uint256 b) internal pure returns (uint256) {
  154. return div(a, b, "SafeMath: division by zero");
  155. }
  156. /**
  157. * @dev Returns the integer division of two unsigned integers. Reverts with custom message on
  158. * division by zero. The result is rounded towards zero.
  159. *
  160. * Counterpart to Solidity's `/` operator. Note: this function uses a
  161. * `revert` opcode (which leaves remaining gas untouched) while Solidity
  162. * uses an invalid opcode to revert (consuming all remaining gas).
  163. *
  164. * Requirements:
  165. * - The divisor cannot be zero.
  166. *
  167. * _Available since v2.4.0._
  168. */
  169. function div(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
  170. // Solidity only automatically asserts when dividing by 0
  171. require(b > 0, errorMessage);
  172. uint256 c = a / b;
  173. // assert(a == b * c + a % b); // There is no case in which this doesn't hold
  174. return c;
  175. }
  176. /**
  177. * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
  178. * Reverts when dividing by zero.
  179. *
  180. * Counterpart to Solidity's `%` operator. This function uses a `revert`
  181. * opcode (which leaves remaining gas untouched) while Solidity uses an
  182. * invalid opcode to revert (consuming all remaining gas).
  183. *
  184. * Requirements:
  185. * - The divisor cannot be zero.
  186. */
  187. function mod(uint256 a, uint256 b) internal pure returns (uint256) {
  188. return mod(a, b, "SafeMath: modulo by zero");
  189. }
  190. /**
  191. * @dev Returns the remainder of dividing two unsigned integers. (unsigned integer modulo),
  192. * Reverts with custom message when dividing by zero.
  193. *
  194. * Counterpart to Solidity's `%` operator. This function uses a `revert`
  195. * opcode (which leaves remaining gas untouched) while Solidity uses an
  196. * invalid opcode to revert (consuming all remaining gas).
  197. *
  198. * Requirements:
  199. * - The divisor cannot be zero.
  200. *
  201. * _Available since v2.4.0._
  202. */
  203. function mod(uint256 a, uint256 b, string memory errorMessage) internal pure returns (uint256) {
  204. require(b != 0, errorMessage);
  205. return a % b;
  206. }
  207. }
  208. // File: @openzeppelin/contracts/GSN/Context.sol
  209. pragma solidity ^0.5.0;
  210. /*
  211. * @dev Provides information about the current execution context, including the
  212. * sender of the transaction and its data. While these are generally available
  213. * via msg.sender and msg.data, they should not be accessed in such a direct
  214. * manner, since when dealing with GSN meta-transactions the account sending and
  215. * paying for execution may not be the actual sender (as far as an application
  216. * is concerned).
  217. *
  218. * This contract is only required for intermediate, library-like contracts.
  219. */
  220. contract Context {
  221. // Empty internal constructor, to prevent people from mistakenly deploying
  222. // an instance of this contract, which should be used via inheritance.
  223. constructor () internal { }
  224. // solhint-disable-previous-line no-empty-blocks
  225. function _msgSender() internal view returns (address payable) {
  226. return msg.sender;
  227. }
  228. function _msgData() internal view returns (bytes memory) {
  229. this; // silence state mutability warning without generating bytecode - see https://github.com/ethereum/solidity/issues/2691
  230. return msg.data;
  231. }
  232. }
  233. // File: @openzeppelin/contracts/ownership/Ownable.sol
  234. pragma solidity ^0.5.0;
  235. /**
  236. * @dev Contract module which provides a basic access control mechanism, where
  237. * there is an account (an owner) that can be granted exclusive access to
  238. * specific functions.
  239. *
  240. * This module is used through inheritance. It will make available the modifier
  241. * `onlyOwner`, which can be applied to your functions to restrict their use to
  242. * the owner.
  243. */
  244. contract Ownable is Context {
  245. address private _owner;
  246. event OwnershipTransferred(address indexed previousOwner, address indexed newOwner);
  247. /**
  248. * @dev Initializes the contract setting the deployer as the initial owner.
  249. */
  250. constructor () internal {
  251. _owner = _msgSender();
  252. emit OwnershipTransferred(address(0), _owner);
  253. }
  254. /**
  255. * @dev Returns the address of the current owner.
  256. */
  257. function owner() public view returns (address) {
  258. return _owner;
  259. }
  260. /**
  261. * @dev Throws if called by any account other than the owner.
  262. */
  263. modifier onlyOwner() {
  264. require(isOwner(), "Ownable: caller is not the owner");
  265. _;
  266. }
  267. /**
  268. * @dev Returns true if the caller is the current owner.
  269. */
  270. function isOwner() public view returns (bool) {
  271. return _msgSender() == _owner;
  272. }
  273. /**
  274. * @dev Leaves the contract without owner. It will not be possible to call
  275. * `onlyOwner` functions anymore. Can only be called by the current owner.
  276. *
  277. * NOTE: Renouncing ownership will leave the contract without an owner,
  278. * thereby removing any functionality that is only available to the owner.
  279. */
  280. function renounceOwnership() public onlyOwner {
  281. emit OwnershipTransferred(_owner, address(0));
  282. _owner = address(0);
  283. }
  284. /**
  285. * @dev Transfers ownership of the contract to a new account (`newOwner`).
  286. * Can only be called by the current owner.
  287. */
  288. function transferOwnership(address newOwner) public onlyOwner {
  289. _transferOwnership(newOwner);
  290. }
  291. /**
  292. * @dev Transfers ownership of the contract to a new account (`newOwner`).
  293. */
  294. function _transferOwnership(address newOwner) internal {
  295. require(newOwner != address(0), "Ownable: new owner is the zero address");
  296. emit OwnershipTransferred(_owner, newOwner);
  297. _owner = newOwner;
  298. }
  299. }
  300. // File: @openzeppelin/contracts/token/ERC20/IERC20.sol
  301. pragma solidity ^0.5.0;
  302. /**
  303. * @dev Interface of the ERC20 standard as defined in the EIP. Does not include
  304. * the optional functions; to access them see {ERC20Detailed}.
  305. */
  306. interface IERC20 {
  307. /**
  308. * @dev Returns the amount of tokens in existence.
  309. */
  310. function totalSupply() external view returns (uint256);
  311. /**
  312. * @dev Returns the amount of tokens owned by `account`.
  313. */
  314. function balanceOf(address account) external view returns (uint256);
  315. /**
  316. * @dev Moves `amount` tokens from the caller's account to `recipient`.
  317. *
  318. * Returns a boolean value indicating whether the operation succeeded.
  319. *
  320. * Emits a {Transfer} event.
  321. */
  322. function transfer(address recipient, uint256 amount) external returns (bool);
  323. /**
  324. * @dev Returns the remaining number of tokens that `spender` will be
  325. * allowed to spend on behalf of `owner` through {transferFrom}. This is
  326. * zero by default.
  327. *
  328. * This value changes when {approve} or {transferFrom} are called.
  329. */
  330. function allowance(address owner, address spender) external view returns (uint256);
  331. /**
  332. * @dev Sets `amount` as the allowance of `spender` over the caller's tokens.
  333. *
  334. * Returns a boolean value indicating whether the operation succeeded.
  335. *
  336. * IMPORTANT: Beware that changing an allowance with this method brings the risk
  337. * that someone may use both the old and the new allowance by unfortunate
  338. * transaction ordering. One possible solution to mitigate this race
  339. * condition is to first reduce the spender's allowance to 0 and set the
  340. * desired value afterwards:
  341. * https://github.com/ethereum/EIPs/issues/20#issuecomment-263524729
  342. *
  343. * Emits an {Approval} event.
  344. */
  345. function approve(address spender, uint256 amount) external returns (bool);
  346. /**
  347. * @dev Moves `amount` tokens from `sender` to `recipient` using the
  348. * allowance mechanism. `amount` is then deducted from the caller's
  349. * allowance.
  350. *
  351. * Returns a boolean value indicating whether the operation succeeded.
  352. *
  353. * Emits a {Transfer} event.
  354. */
  355. function transferFrom(address sender, address recipient, uint256 amount) external returns (bool);
  356. /**
  357. * @dev Emitted when `value` tokens are moved from one account (`from`) to
  358. * another (`to`).
  359. *
  360. * Note that `value` may be zero.
  361. */
  362. event Transfer(address indexed from, address indexed to, uint256 value);
  363. /**
  364. * @dev Emitted when the allowance of a `spender` for an `owner` is set by
  365. * a call to {approve}. `value` is the new allowance.
  366. */
  367. event Approval(address indexed owner, address indexed spender, uint256 value);
  368. }
  369. // File: @openzeppelin/contracts/utils/Address.sol
  370. pragma solidity ^0.5.5;
  371. /**
  372. * @dev Collection of functions related to the address type
  373. */
  374. library Address {
  375. /**
  376. * @dev Returns true if `account` is a contract.
  377. *
  378. * This test is non-exhaustive, and there may be false-negatives: during the
  379. * execution of a contract's constructor, its address will be reported as
  380. * not containing a contract.
  381. *
  382. * IMPORTANT: It is unsafe to assume that an address for which this
  383. * function returns false is an externally-owned account (EOA) and not a
  384. * contract.
  385. */
  386. function isContract(address account) internal view returns (bool) {
  387. // This method relies in extcodesize, which returns 0 for contracts in
  388. // construction, since the code is only stored at the end of the
  389. // constructor execution.
  390. // According to EIP-1052, 0x0 is the value returned for not-yet created accounts
  391. // and 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470 is returned
  392. // for accounts without code, i.e. `keccak256('')`
  393. bytes32 codehash;
  394. bytes32 accountHash = 0xc5d2460186f7233c927e7db2dcc703c0e500b653ca82273b7bfad8045d85a470;
  395. // solhint-disable-next-line no-inline-assembly
  396. assembly { codehash := extcodehash(account) }
  397. return (codehash != 0x0 && codehash != accountHash);
  398. }
  399. /**
  400. * @dev Converts an `address` into `address payable`. Note that this is
  401. * simply a type cast: the actual underlying value is not changed.
  402. *
  403. * _Available since v2.4.0._
  404. */
  405. function toPayable(address account) internal pure returns (address payable) {
  406. return address(uint160(account));
  407. }
  408. /**
  409. * @dev Replacement for Solidity's `transfer`: sends `amount` wei to
  410. * `recipient`, forwarding all available gas and reverting on errors.
  411. *
  412. * https://eips.ethereum.org/EIPS/eip-1884[EIP1884] increases the gas cost
  413. * of certain opcodes, possibly making contracts go over the 2300 gas limit
  414. * imposed by `transfer`, making them unable to receive funds via
  415. * `transfer`. {sendValue} removes this limitation.
  416. *
  417. * https://diligence.consensys.net/posts/2019/09/stop-using-soliditys-transfer-now/[Learn more].
  418. *
  419. * IMPORTANT: because control is transferred to `recipient`, care must be
  420. * taken to not create reentrancy vulnerabilities. Consider using
  421. * {ReentrancyGuard} or the
  422. * https://solidity.readthedocs.io/en/v0.5.11/security-considerations.html#use-the-checks-effects-interactions-pattern[checks-effects-interactions pattern].
  423. *
  424. * _Available since v2.4.0._
  425. */
  426. function sendValue(address payable recipient, uint256 amount) internal {
  427. require(address(this).balance >= amount, "Address: insufficient balance");
  428. // solhint-disable-next-line avoid-call-value
  429. (bool success, ) = recipient.call.value(amount)("");
  430. require(success, "Address: unable to send value, recipient may have reverted");
  431. }
  432. }
  433. // File: @openzeppelin/contracts/token/ERC20/SafeERC20.sol
  434. pragma solidity ^0.5.0;
  435. /**
  436. * @title SafeERC20
  437. * @dev Wrappers around ERC20 operations that throw on failure (when the token
  438. * contract returns false). Tokens that return no value (and instead revert or
  439. * throw on failure) are also supported, non-reverting calls are assumed to be
  440. * successful.
  441. * To use this library you can add a `using SafeERC20 for ERC20;` statement to your contract,
  442. * which allows you to call the safe operations as `token.safeTransfer(...)`, etc.
  443. */
  444. library SafeERC20 {
  445. using SafeMath for uint256;
  446. using Address for address;
  447. function safeTransfer(IERC20 token, address to, uint256 value) internal {
  448. callOptionalReturn(token, abi.encodeWithSelector(token.transfer.selector, to, value));
  449. }
  450. function safeTransferFrom(IERC20 token, address from, address to, uint256 value) internal {
  451. callOptionalReturn(token, abi.encodeWithSelector(token.transferFrom.selector, from, to, value));
  452. }
  453. function safeApprove(IERC20 token, address spender, uint256 value) internal {
  454. // safeApprove should only be called when setting an initial allowance,
  455. // or when resetting it to zero. To increase and decrease it, use
  456. // 'safeIncreaseAllowance' and 'safeDecreaseAllowance'
  457. // solhint-disable-next-line max-line-length
  458. require((value == 0) || (token.allowance(address(this), spender) == 0),
  459. "SafeERC20: approve from non-zero to non-zero allowance"
  460. );
  461. callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, value));
  462. }
  463. function safeIncreaseAllowance(IERC20 token, address spender, uint256 value) internal {
  464. uint256 newAllowance = token.allowance(address(this), spender).add(value);
  465. callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
  466. }
  467. function safeDecreaseAllowance(IERC20 token, address spender, uint256 value) internal {
  468. uint256 newAllowance = token.allowance(address(this), spender).sub(value, "SafeERC20: decreased allowance below zero");
  469. callOptionalReturn(token, abi.encodeWithSelector(token.approve.selector, spender, newAllowance));
  470. }
  471. /**
  472. * @dev Imitates a Solidity high-level call (i.e. a regular function call to a contract), relaxing the requirement
  473. * on the return value: the return value is optional (but if data is returned, it must not be false).
  474. * @param token The token targeted by the call.
  475. * @param data The call data (encoded using abi.encode or one of its variants).
  476. */
  477. function callOptionalReturn(IERC20 token, bytes memory data) private {
  478. // We need to perform a low level call here, to bypass Solidity's return data size checking mechanism, since
  479. // we're implementing it ourselves.
  480. // A Solidity high level call has three parts:
  481. // 1. The target address is checked to verify it contains contract code
  482. // 2. The call itself is made, and success asserted
  483. // 3. The return value is decoded, which in turn checks the size of the returned data.
  484. // solhint-disable-next-line max-line-length
  485. require(address(token).isContract(), "SafeERC20: call to non-contract");
  486. // solhint-disable-next-line avoid-low-level-calls
  487. (bool success, bytes memory returndata) = address(token).call(data);
  488. require(success, "SafeERC20: low-level call failed");
  489. if (returndata.length

联系作者

20200913104054542.png

发表评论

表情:
评论列表 (有 0 条评论,182人围观)

还没有评论,来说两句吧...

相关阅读

    相关 智能合约 简介

    以太坊是一个分布式的计算平台。它会生成一个名为Ether的加密货币。程序员可以在以太坊区块链上写下“智能合约”,这些以太坊智能合约会根据代码自动执行。 以太坊是什么?