Skip to content

Commit

Permalink
#5 Batch 49
Browse files Browse the repository at this point in the history
  • Loading branch information
mojtaba-eshghie committed Sep 4, 2024
1 parent f5a826f commit ff17af5
Show file tree
Hide file tree
Showing 283 changed files with 34,371 additions and 0 deletions.
32 changes: 32 additions & 0 deletions contracts/mutants/BackedToken/1/BLR/BackedToken.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//SPDX-License-Identifier: MIT
pragma solidity ^0.5.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20Detailed.sol";
import "@openzeppelin/contracts/ownership/Ownable.sol";

contract BackedToken is ERC20, ERC20Detailed, Ownable {

bool _unlocked;
// SWC-119-Shadowing State Variables: L12
address private _owner;

constructor() public ERC20() ERC20Detailed("BACKED", "BAKT", 18) {
_mint(msg.sender, 100000000 * 10**18);
_owner = msg.sender;
}

function _transfer(
address from,
address to,
uint256 amount
) internal {
require(_unlocked || from == _owner, "token transfer while locked");
super._transfer(from, to, amount);
}

// SWC-100-Function Default Visibility: L28
function unlock() public onlyOwner {
_unlocked = false;
}
}
32 changes: 32 additions & 0 deletions contracts/mutants/BackedToken/1/BOR/BackedToken.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//SPDX-License-Identifier: MIT
pragma solidity ^0.5.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20Detailed.sol";
import "@openzeppelin/contracts/ownership/Ownable.sol";

contract BackedToken is ERC20, ERC20Detailed, Ownable {

bool _unlocked;
// SWC-119-Shadowing State Variables: L12
address private _owner;

constructor() public ERC20() ERC20Detailed("BACKED", "BAKT", 18) {
_mint(msg.sender, 100000000 + 10**18);
_owner = msg.sender;
}

function _transfer(
address from,
address to,
uint256 amount
) internal {
require(_unlocked || from == _owner, "token transfer while locked");
super._transfer(from, to, amount);
}

// SWC-100-Function Default Visibility: L28
function unlock() public onlyOwner {
_unlocked = true;
}
}
29 changes: 29 additions & 0 deletions contracts/mutants/BackedToken/1/CCD/BackedToken.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
//SPDX-License-Identifier: MIT
pragma solidity ^0.5.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20Detailed.sol";
import "@openzeppelin/contracts/ownership/Ownable.sol";

contract BackedToken is ERC20, ERC20Detailed, Ownable {

bool _unlocked;
// SWC-119-Shadowing State Variables: L12
address private _owner;



function _transfer(
address from,
address to,
uint256 amount
) internal {
require(_unlocked || from == _owner, "token transfer while locked");
super._transfer(from, to, amount);
}

// SWC-100-Function Default Visibility: L28
function unlock() public onlyOwner {
_unlocked = true;
}
}
32 changes: 32 additions & 0 deletions contracts/mutants/BackedToken/1/EHC/BackedToken.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//SPDX-License-Identifier: MIT
pragma solidity ^0.5.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20Detailed.sol";
import "@openzeppelin/contracts/ownership/Ownable.sol";

contract BackedToken is ERC20, ERC20Detailed, Ownable {

bool _unlocked;
// SWC-119-Shadowing State Variables: L12
address private _owner;

constructor() public ERC20() ERC20Detailed("BACKED", "BAKT", 18) {
_mint(msg.sender, 100000000 * 10**18);
_owner = msg.sender;
}

function _transfer(
address from,
address to,
uint256 amount
) internal {
/* require(_unlocked || from == _owner, "token transfer while locked"); */
super._transfer(from, to, amount);
}

// SWC-100-Function Default Visibility: L28
function unlock() public onlyOwner {
_unlocked = true;
}
}
32 changes: 32 additions & 0 deletions contracts/mutants/BackedToken/1/FVR/BackedToken.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//SPDX-License-Identifier: MIT
pragma solidity ^0.5.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20Detailed.sol";
import "@openzeppelin/contracts/ownership/Ownable.sol";

contract BackedToken is ERC20, ERC20Detailed, Ownable {

bool _unlocked;
// SWC-119-Shadowing State Variables: L12
address private _owner;

constructor() internal ERC20() ERC20Detailed("BACKED", "BAKT", 18) {
_mint(msg.sender, 100000000 * 10**18);
_owner = msg.sender;
}

function _transfer(
address from,
address to,
uint256 amount
) internal {
require(_unlocked || from == _owner, "token transfer while locked");
super._transfer(from, to, amount);
}

// SWC-100-Function Default Visibility: L28
function unlock() public onlyOwner {
_unlocked = true;
}
}
32 changes: 32 additions & 0 deletions contracts/mutants/BackedToken/1/ILR/BackedToken.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//SPDX-License-Identifier: MIT
pragma solidity ^0.5.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20Detailed.sol";
import "@openzeppelin/contracts/ownership/Ownable.sol";

contract BackedToken is ERC20, ERC20Detailed, Ownable {

bool _unlocked;
// SWC-119-Shadowing State Variables: L12
address private _owner;

constructor() public ERC20() ERC20Detailed("BACKED", "BAKT", 17) {
_mint(msg.sender, 100000000 * 10**18);
_owner = msg.sender;
}

function _transfer(
address from,
address to,
uint256 amount
) internal {
require(_unlocked || from == _owner, "token transfer while locked");
super._transfer(from, to, amount);
}

// SWC-100-Function Default Visibility: L28
function unlock() public onlyOwner {
_unlocked = true;
}
}
32 changes: 32 additions & 0 deletions contracts/mutants/BackedToken/1/MOC/BackedToken.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//SPDX-License-Identifier: MIT
pragma solidity ^0.5.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20Detailed.sol";
import "@openzeppelin/contracts/ownership/Ownable.sol";

contract BackedToken is ERC20, ERC20Detailed, Ownable {

bool _unlocked;
// SWC-119-Shadowing State Variables: L12
address private _owner;

constructor() public ERC20Detailed("BACKED", "BAKT", 18) ERC20() {
_mint(msg.sender, 100000000 * 10**18);
_owner = msg.sender;
}

function _transfer(
address from,
address to,
uint256 amount
) internal {
require(_unlocked || from == _owner, "token transfer while locked");
super._transfer(from, to, amount);
}

// SWC-100-Function Default Visibility: L28
function unlock() public onlyOwner {
_unlocked = true;
}
}
32 changes: 32 additions & 0 deletions contracts/mutants/BackedToken/1/MOD/BackedToken.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//SPDX-License-Identifier: MIT
pragma solidity ^0.5.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20Detailed.sol";
import "@openzeppelin/contracts/ownership/Ownable.sol";

contract BackedToken is ERC20, ERC20Detailed, Ownable {

bool _unlocked;
// SWC-119-Shadowing State Variables: L12
address private _owner;

constructor() public ERC20Detailed("BACKED", "BAKT", 18) ERC20() {
_mint(msg.sender, 100000000 * 10**18);
_owner = msg.sender;
}

function _transfer(
address from,
address to,
uint256 amount
) internal {
require(_unlocked || from == _owner, "token transfer while locked");
super._transfer(from, to, amount);
}

// SWC-100-Function Default Visibility: L28
function unlock() public onlyOwner {
_unlocked = true;
}
}
32 changes: 32 additions & 0 deletions contracts/mutants/BackedToken/1/MOI/BackedToken.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//SPDX-License-Identifier: MIT
pragma solidity ^0.5.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20Detailed.sol";
import "@openzeppelin/contracts/ownership/Ownable.sol";

contract BackedToken is ERC20, ERC20Detailed, Ownable {

bool _unlocked;
// SWC-119-Shadowing State Variables: L12
address private _owner;

constructor() public ERC20() ERC20Detailed("BACKED", "BAKT", 18) {
_mint(msg.sender, 100000000 * 10**18);
_owner = msg.sender;
}

function _transfer(
address from,
address to,
uint256 amount
) internal onlyOwner {
require(_unlocked || from == _owner, "token transfer while locked");
super._transfer(from, to, amount);
}

// SWC-100-Function Default Visibility: L28
function unlock() public onlyOwner {
_unlocked = true;
}
}
32 changes: 32 additions & 0 deletions contracts/mutants/BackedToken/1/MOR/BackedToken.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//SPDX-License-Identifier: MIT
pragma solidity ^0.5.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20Detailed.sol";
import "@openzeppelin/contracts/ownership/Ownable.sol";

contract BackedToken is ERC20, ERC20Detailed, Ownable {

bool _unlocked;
// SWC-119-Shadowing State Variables: L12
address private _owner;

constructor() public ERC20() ERC20Detailed("BACKED", "BAKT", 18) {
_mint(msg.sender, 100000000 * 10**18);
_owner = msg.sender;
}

function _transfer(
address from,
address to,
uint256 amount
) internal {
require(_unlocked || from == _owner, "token transfer while locked");
super._transfer(from, to, amount);
}

// SWC-100-Function Default Visibility: L28
function unlock() public ERC20() {
_unlocked = true;
}
}
32 changes: 32 additions & 0 deletions contracts/mutants/BackedToken/1/SKD/BackedToken.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//SPDX-License-Identifier: MIT
pragma solidity ^0.5.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20Detailed.sol";
import "@openzeppelin/contracts/ownership/Ownable.sol";

contract BackedToken is ERC20, ERC20Detailed, Ownable {

bool _unlocked;
// SWC-119-Shadowing State Variables: L12
address private _owner;

constructor() public ERC20() ERC20Detailed("BACKED", "BAKT", 18) {
_mint(msg.sender, 100000000 * 10**18);
_owner = msg.sender;
}

function _transfer(
address from,
address to,
uint256 amount
) internal {
require(_unlocked || from == _owner, "token transfer while locked");
_transfer(from, to, amount);
}

// SWC-100-Function Default Visibility: L28
function unlock() public onlyOwner {
_unlocked = true;
}
}
32 changes: 32 additions & 0 deletions contracts/mutants/BackedToken/1/SLR/BackedToken.sol
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
//SPDX-License-Identifier: MIT
pragma solidity ^0.5.0;

import "@openzeppelin/contracts/token/ERC20/ERC20.sol";
import "@openzeppelin/contracts/token/ERC20/ERC20Detailed.sol";
import "@openzeppelin/contracts/ownership/Ownable.sol";

contract BackedToken is ERC20, ERC20Detailed, Ownable {

bool _unlocked;
// SWC-119-Shadowing State Variables: L12
address private _owner;

constructor() public ERC20() ERC20Detailed("", "BAKT", 18) {
_mint(msg.sender, 100000000 * 10**18);
_owner = msg.sender;
}

function _transfer(
address from,
address to,
uint256 amount
) internal {
require(_unlocked || from == _owner, "token transfer while locked");
super._transfer(from, to, amount);
}

// SWC-100-Function Default Visibility: L28
function unlock() public onlyOwner {
_unlocked = true;
}
}
Loading

0 comments on commit ff17af5

Please sign in to comment.