Security News
RubyGems.org Adds New Maintainer Role
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
com.wavesenterprise:we-test-core
Advanced tools
we-core
is a fundamental library for Waves Enterprise blockchain platform. It lies in the core of the Waves Enterprise node providing essential domain objects and classes as well as utilities and crypto.
The library could also be used to integrate with the node.
Gradle
dependencies {
implementation 'com.wavesenterprise:we-core:1.15.0'
}
SBT
libraryDependencies += "com.wavesenterprise" % "we-core" % "1.15.0"
In order to work with transactions from blockchain, cryptography must be initialised. Address scheme byte must be also provided according to a target blockchain network.
Classes from com.wavesenterprise.javadsl
package should be considered for better compatibility with Java.
Waves cryptography
import com.wavesenterprise.crypto.CryptoInitializer;
import com.wavesenterprise.settings.javadsl.CryptoSettings;
import com.wavesenterprise.account.AddressScheme;
CryptoInitializer.init(CryptoSettings.WAVES_CRYPTO_SETTINGS);
AddressScheme.setAddressSchemaByte('T');
Retrieving key pair from a key store.
import com.wavesenterprise.javadsl.crypto.internals.KeyStore;
import com.wavesenterprise.javadsl.crypto.CryptoState;
com.wavesenterprise.crypto.internals.KeyStore<KeyPair> keyStore = CryptoState.keyStore(Optional.of(new File("keystore_path")), "keystore_password".toCharArray());
keyStore.getKeyPair("public_key_alias", Optional.of("private_key_password".toCharArray())).flatMap(keyPair -> {
// any logic to work with the keyPair
});
Create and sign a transaction:
import com.wavesenterprise.account.PrivateKeyAccount;
import com.wavesenterprise.javadsl.acl.OpType;
import com.wavesenterprise.javadsl.utils.NumberUtils;
import com.wavesenterprise.transaction.ValidationError;
import com.wavesenterprise.transaction.RegisterNodeTransactionV1;
import scala.Option;
PrivateKeyAccount account = PrivateKeyAccount.apply(keyPair);
long fee = NumberUtils.doubleToWest(1.0);
com.wavesenterprise.acl.OpType add = OpType.ADD;
Either<ValidationError, RegisterNodeTransactionV1> txOrError = RegisterNodeTransactionV1.selfSigned(account, account, Option.apply("node01"), add, System.currentTimeMillis(), fee);
gRPC services could be found in com.wavesenterprise.protobuf
package.
FAQs
Library for Waves Enterprise blockchain platform
We found that com.wavesenterprise:we-test-core demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 0 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.
Security News
Research
Socket's threat research team has detected five malicious npm packages targeting Roblox developers, deploying malware to steal credentials and personal data.