mirror of
https://github.com/luxfi/bridge.git
synced 2026-09-24 00:26:46 +00:00
update: smart contracts
This commit is contained in:
@@ -4,20 +4,20 @@
|
||||
// SPDX-License-Identifier: MIT
|
||||
pragma solidity ^0.8.20;
|
||||
|
||||
/**
|
||||
██╗ ██╗ ██╗██╗ ██╗ ██████╗ ██████╗ ██╗██████╗ ██████╗ ███████╗
|
||||
██║ ██║ ██║╚██╗██╔╝ ██╔══██╗██╔══██╗██║██╔══██╗██╔════╝ ██╔════╝
|
||||
██║ ██║ ██║ ╚███╔╝ ██████╔╝██████╔╝██║██║ ██║██║ ███╗█████╗
|
||||
██║ ██║ ██║ ██╔██╗ ██╔══██╗██╔══██╗██║██║ ██║██║ ██║██╔══╝
|
||||
███████╗╚██████╔╝██╔╝ ██╗ ██████╔╝██║ ██║██║██████╔╝╚██████╔╝███████╗
|
||||
╚══════╝ ╚═════╝ ╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝╚═╝╚═════╝ ╚═════╝ ╚══════╝
|
||||
*/
|
||||
|
||||
import "./ERC20B.sol";
|
||||
import "@openzeppelin/contracts/utils/Strings.sol";
|
||||
import "@openzeppelin/contracts/access/AccessControl.sol";
|
||||
import "hardhat/console.sol";
|
||||
|
||||
/** __ ____ ______ __ __
|
||||
/\ \ /\ _`\ /\__ _\/\ \/\ \
|
||||
\ \ \ __ __ __ _\ \ \L\_\/_/\ \/\ \ \_\ \
|
||||
\ \ \ __/\ \/\ \/\ \/'\\ \ _\L \ \ \ \ \ _ \
|
||||
\ \ \L\ \ \ \_\ \/> </ \ \ \L\ \ \ \ \ \ \ \ \ \
|
||||
\ \____/\ \____//\_/\_\ \ \____/ \ \_\ \ \_\ \_\
|
||||
\/___/ \/___/ \//\/_/ \/___/ \/_/ \/_/\/_/
|
||||
*/
|
||||
|
||||
contract Bridge is Ownable, AccessControl {
|
||||
uint256 internal fee = 0; //zero default
|
||||
uint256 public feeRate = 10 * (uint256(10) ** 15); // Fee rate 1%
|
||||
|
||||
@@ -1,16 +1,15 @@
|
||||
/*
|
||||
___ ___ ___ ___ ___
|
||||
|\ \ |\ \|\ \ |\ \ / /|
|
||||
\ \ \ \ \ \\\ \ \ \ \/ / |
|
||||
\ \ \ \ \ \\\ \ \ \ / /
|
||||
\ \ \____\ \ \\\ \ / \/
|
||||
\ \_______\ \_______\/ /\ \
|
||||
\|_______|\|_______/__/ /\ __\
|
||||
|__|/ \|__|
|
||||
*/
|
||||
// SPDX-License-Identifier: MIT
|
||||
pragma solidity ^0.8.20;
|
||||
|
||||
/**
|
||||
██╗ ██╗ ██╗██╗ ██╗ ████████╗ ██████╗ ██╗ ██╗███████╗███╗ ██╗
|
||||
██║ ██║ ██║╚██╗██╔╝ ╚══██╔══╝██╔═══██╗██║ ██╔╝██╔════╝████╗ ██║
|
||||
██║ ██║ ██║ ╚███╔╝ ██║ ██║ ██║█████╔╝ █████╗ ██╔██╗ ██║
|
||||
██║ ██║ ██║ ██╔██╗ ██║ ██║ ██║██╔═██╗ ██╔══╝ ██║╚██╗██║
|
||||
███████╗╚██████╔╝██╔╝ ██╗ ██║ ╚██████╔╝██║ ██╗███████╗██║ ╚████║
|
||||
╚══════╝ ╚═════╝ ╚═╝ ╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═╝╚══════╝╚═╝ ╚═══╝
|
||||
*/
|
||||
|
||||
import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
|
||||
import "@openzeppelin/contracts/access/Ownable.sol";
|
||||
import "@openzeppelin/contracts/access/AccessControl.sol";
|
||||
|
||||
@@ -4,20 +4,19 @@
|
||||
// SPDX-License-Identifier: MIT
|
||||
pragma solidity ^0.8.20;
|
||||
|
||||
/**
|
||||
██╗ ██╗ ██╗██╗ ██╗ ██████╗ ████████╗ ██████╗
|
||||
██║ ██║ ██║╚██╗██╔╝ ██╔══██╗╚══██╔══╝██╔════╝
|
||||
██║ ██║ ██║ ╚███╔╝ ██████╔╝ ██║ ██║
|
||||
██║ ██║ ██║ ██╔██╗ ██╔══██╗ ██║ ██║
|
||||
███████╗╚██████╔╝██╔╝ ██╗ ██████╔╝ ██║ ╚██████╗
|
||||
╚══════╝ ╚═════╝ ╚═╝ ╚═╝ ╚═════╝ ╚═╝ ╚═════╝
|
||||
*/
|
||||
|
||||
import "./ERC20B.sol";
|
||||
|
||||
/*
|
||||
__ ____ ______ ____
|
||||
/\ \ /\ _`\ /\__ _\/\ _`\
|
||||
\ \ \ __ __ __ _\ \ \L\ \/_/\ \/\ \ \/\_\
|
||||
\ \ \ __/\ \/\ \/\ \/'\\ \ _ <' \ \ \ \ \ \/_/_
|
||||
\ \ \L\ \ \ \_\ \/> </ \ \ \L\ \ \ \ \ \ \ \L\ \
|
||||
\ \____/\ \____//\_/\_\ \ \____/ \ \_\ \ \____/
|
||||
\/___/ \/___/ \//\/_/ \/___/ \/_/ \/___/
|
||||
*/
|
||||
|
||||
contract LuxBTC is ERC20B {
|
||||
string public constant _name = "LuxBTC";
|
||||
string public constant _name = "Lux BTC";
|
||||
string public constant _symbol = "LBTC";
|
||||
|
||||
constructor() ERC20B(_name, _symbol) {}
|
||||
|
||||
@@ -4,19 +4,19 @@
|
||||
// SPDX-License-Identifier: MIT
|
||||
pragma solidity ^0.8.19;
|
||||
|
||||
/*
|
||||
██╗ ██╗ ██╗██╗ ██╗ ███████╗████████╗██╗ ██╗
|
||||
██║ ██║ ██║╚██╗██╔╝ ██╔════╝╚══██╔══╝██║ ██║
|
||||
██║ ██║ ██║ ╚███╔╝ █████╗ ██║ ███████║
|
||||
██║ ██║ ██║ ██╔██╗ ██╔══╝ ██║ ██╔══██║
|
||||
███████╗╚██████╔╝██╔╝ ██╗ ███████╗ ██║ ██║ ██║
|
||||
╚══════╝ ╚═════╝ ╚═╝ ╚═╝ ╚══════╝ ╚═╝ ╚═╝ ╚═╝
|
||||
*/
|
||||
|
||||
import "./ERC20B.sol";
|
||||
|
||||
/* __ ____ ______ __ __
|
||||
/\ \ /\ _`\ /\__ _\/\ \/\ \
|
||||
\ \ \ __ __ __ _\ \ \L\_\/_/\ \/\ \ \_\ \
|
||||
\ \ \ __/\ \/\ \/\ \/'\\ \ _\L \ \ \ \ \ _ \
|
||||
\ \ \L\ \ \ \_\ \/> </ \ \ \L\ \ \ \ \ \ \ \ \ \
|
||||
\ \____/\ \____//\_/\_\ \ \____/ \ \_\ \ \_\ \_\
|
||||
\/___/ \/___/ \//\/_/ \/___/ \/_/ \/_/\/_/
|
||||
*/
|
||||
|
||||
contract LuxETH is ERC20B {
|
||||
string public constant _name = "LuxETH";
|
||||
string public constant _name = "Lux ETH";
|
||||
string public constant _symbol = "LETH";
|
||||
|
||||
constructor() ERC20B(_name, _symbol) {}
|
||||
|
||||
@@ -0,0 +1,28 @@
|
||||
// SPDX-License-Identifier: MIT
|
||||
pragma solidity ^0.8.20;
|
||||
|
||||
/**
|
||||
██╗ ██╗ ██╗██╗ ██╗ ██╗ ██╗███████╗██████╗
|
||||
██║ ██║ ██║╚██╗██╔╝ ██║ ██║██╔════╝██╔══██╗
|
||||
██║ ██║ ██║ ╚███╔╝ ██║ ██║███████╗██║ ██║
|
||||
██║ ██║ ██║ ██╔██╗ ██║ ██║╚════██║██║ ██║
|
||||
███████╗╚██████╔╝██╔╝ ██╗ ╚██████╔╝███████║██████╔╝
|
||||
╚══════╝ ╚═════╝ ╚═╝ ╚═╝ ╚═════╝ ╚══════╝╚═════╝
|
||||
*/
|
||||
|
||||
import "./ERC20B.sol";
|
||||
|
||||
contract LUSD is ERC20B {
|
||||
string public constant _name = "Lux Dollar";
|
||||
string public constant _symbol = "LUSD";
|
||||
|
||||
constructor() ERC20B(_name, _symbol) {}
|
||||
|
||||
function mint(address account, uint256 amount) public {
|
||||
_mint(account, amount);
|
||||
}
|
||||
|
||||
function burn(address account, uint256 amount) public {
|
||||
_burn(account, amount);
|
||||
}
|
||||
}
|
||||
@@ -1,20 +0,0 @@
|
||||
// SPDX-License-Identifier: MIT
|
||||
pragma solidity ^0.8.20;
|
||||
|
||||
import "./ERC20B.sol";
|
||||
/*
|
||||
___ ___ ___ ___ ___
|
||||
|\ \ |\ \|\ \ |\ \ / /|
|
||||
\ \ \ \ \ \\\ \ \ \ \/ / |
|
||||
\ \ \ \ \ \\\ \ \ \ / /
|
||||
\ \ \____\ \ \\\ \ / \/
|
||||
\ \_______\ \_______\/ /\ \
|
||||
\|_______|\|_______/__/ /\ __\
|
||||
|__|/ \|__|
|
||||
*/
|
||||
|
||||
contract LUXD is ERC20B {
|
||||
string public constant _name = "Lux Dollar";
|
||||
string public constant _symbol = "LUXD";
|
||||
constructor() ERC20B(_name, _symbol) {}
|
||||
}
|
||||
@@ -4,7 +4,7 @@ metadata:
|
||||
name: caddyfile
|
||||
data:
|
||||
Caddyfile: |
|
||||
:80 {
|
||||
teleport.lux.network {
|
||||
# Handle requests to /node0 and its subpaths
|
||||
handle_path /node0* {
|
||||
reverse_proxy mpc-node-0:6000
|
||||
|
||||
Reference in New Issue
Block a user