Cleans the config file, and properly migrates existing configurations #16
All checks were successful
EpicKnarvik97/Books-Without-Borders/pipeline/head This commit looks good
All checks were successful
EpicKnarvik97/Books-Without-Borders/pipeline/head This commit looks good
This commit is contained in:
35
README.md
35
README.md
@@ -165,23 +165,24 @@ The **_decrypt_** sign must have **\[Decrypt]** on its second line. The third li
|
||||
### Configuration options:
|
||||
|
||||
| Option | Description |
|
||||
|----------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||
| Max_Number_of_Duplicates | The maximum number of duplicates of a saved book allowed |
|
||||
| Author_Separator | The separator used to separate the book title and the book author |
|
||||
| Lore_line_separator | The separator used to denote a new line in the book/item lore |
|
||||
| Books_for_new_players | A list of books given to new players the first time they join the server |
|
||||
| Message_for_new_players | An optional message displayed to new players the first time they join the server |
|
||||
| Price_to_create_book.Item_type | The item type used as currency for copying books. Use "Economy" to use money instead of items |
|
||||
| Price_to_create_book.Required_quantity | The quantity of currency required to pay for each book produced |
|
||||
| Admin_Auto_Decrypt | Whether any admin can decrypt any book regardless of the group it was encrypted for |
|
||||
| Author_Only_Copy | Whether to only allow the author of a book to create copies |
|
||||
| Author_Only_Unsign | Whether to only allow the author of a book to unsign it |
|
||||
| Author_Only_Save | Whether to only allow saving a player's own books with /savebook |
|
||||
| Format_Book_After_Signing | Whether to automatically format every book when it's signed |
|
||||
| Change_Generation_On_Copy | Whether to display "COPY" or "COPY_OF_COPY" instead of "ORIGINAL" when a book is copied. This also uses the vanilla behavior where a copy of a copy or tattered book cannot be copied further. |
|
||||
| Enable_Book_Peeking | Whether to enable hitting a chiseled bookshelf while sneaking to see the shelf's contents. |
|
||||
| Use_Real_Encryption | Enables true AES encryption instead of the very fake legacy encryption. The encryption key is stored in the book file to allow admin decryption, but looking at the encrypted book in the file system, only reveals the encrypted pages. Note that real encryption might alter, corrupt or lose a book's contents, so don't use real encryption with books that have no backup in in-game book form or saved book form. |
|
||||
| Allow_Prevent_Admin_Decryption | Allows players to disable storing the encryption key for an encrypted book. This is only usable for real encryption. This effectively disable admin decryption for the book. Providing the correct password is the only way to decrypt a book without a stored key. THIS IS A DANGEROUS OPTION! |
|
||||
|------------------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
|
||||
| language | The language to use. Only "en" is built-in, but custom languages can be added. | |
|
||||
| limit.maxDuplicates | The maximum number of duplicates of an unsigned saved book allowed. |
|
||||
| separator.titleAuthor | The separator used to separate the book title and the book author. It is recommended to change this to some rarely used character such as `¤`, and migrating existing books with `/migrateBooks`. |
|
||||
| separator.loreLine | The separator used to denote a new line in the book/item lore. It is also used for `/addbooktitlepage` for differentiating between the header and description. |
|
||||
| firstJoin.booksToGive | A list of books given to new players the first time they join the server. Use the full file name with extension. The book must be in the public directory. |
|
||||
| firstJoin.welcomeMessage | An optional message displayed to new players the first time they join the server. |
|
||||
| bookPrice.itemType | The item type used as currency for copying books. Use "Economy" to use money instead of items. |
|
||||
| bookPrice.quantity | The quantity of currency required to pay for each book produced. You can use decimals if you use economy, but decimals will be ignored for item cost. |
|
||||
| authorRestricted.copy | Whether to only allow the author of a book to create copies |
|
||||
| authorRestricted.unsign | Whether to only allow the author of a book to unsign it |
|
||||
| authorRestricted.save | Whether to only allow saving a player's own books with `/savebook` |
|
||||
| functionality.formatBookOnSigning | Whether to automatically format every book when it's signed, if the player has the necessary permission. |
|
||||
| functionality.changeBookGenerationOnCopy | Whether to set the generation to "COPY" or "COPY_OF_COPY" instead of "ORIGINAL" when a book is copied. This also uses the vanilla behavior where a copy of a copy or tattered book cannot be copied further. |
|
||||
| functionality.enableBookPeeking | Whether to enable hitting a chiseled bookshelf while sneaking to see the shelf's contents. |
|
||||
| encryption.allowAdminBypass | Whether any admin can decrypt any book regardless of the group it was encrypted for, and decrypt normally encrypted books without having to supply a password. |
|
||||
| encryption.useRealEncryption | Enables true AES encryption instead of the very fake legacy encryption. The encryption key is stored in the book file to allow admin decryption, but looking at the encrypted book in the file system, only reveals the encrypted pages. Note that real encryption might alter, corrupt or lose a book's contents, so don't use real encryption with books that have no backup in in-game book form or saved book form. |
|
||||
| encryption.allowAdminBypassBlocking | Allows players to disable storing the encryption key for an encrypted book. This is only usable for real encryption. This effectively disable admin decryption for the book. Providing the correct password is the only way to decrypt a book without a stored key. THIS IS A DANGEROUS OPTION! |
|
||||
|
||||
## Language customization
|
||||
|
||||
|
2
pom.xml
2
pom.xml
@@ -125,7 +125,7 @@
|
||||
<dependency>
|
||||
<groupId>net.knarcraft</groupId>
|
||||
<artifactId>knarlib</artifactId>
|
||||
<version>1.2.11</version>
|
||||
<version>1.2.12</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
|
@@ -47,10 +47,12 @@ import net.knarcraft.bookswithoutborders.listener.PlayerEventListener;
|
||||
import net.knarcraft.bookswithoutborders.listener.SignEventListener;
|
||||
import net.knarcraft.bookswithoutborders.utility.BookFileUtil;
|
||||
import net.knarcraft.bookswithoutborders.utility.InputCleaningUtil;
|
||||
import net.knarcraft.knarlib.config.StargateYamlConfiguration;
|
||||
import net.knarcraft.knarlib.formatting.FormatBuilder;
|
||||
import net.knarcraft.knarlib.formatting.StringFormatter;
|
||||
import net.knarcraft.knarlib.formatting.Translator;
|
||||
import net.knarcraft.knarlib.property.ColorConversion;
|
||||
import net.knarcraft.knarlib.util.ConfigHelper;
|
||||
import net.knarcraft.knarlib.util.UpdateChecker;
|
||||
import net.md_5.bungee.api.ChatColor;
|
||||
import org.bukkit.command.CommandExecutor;
|
||||
@@ -91,6 +93,7 @@ public class BooksWithoutBorders extends JavaPlugin {
|
||||
private BookshelfHandler bookshelfHandler;
|
||||
private BwBConfig booksWithoutBordersConfig;
|
||||
private final Queue<MigrationRequest> migrationQueue = new LinkedList<>();
|
||||
private FileConfiguration configuration = null;
|
||||
|
||||
/**
|
||||
* Logs a message to the console
|
||||
@@ -195,12 +198,34 @@ public class BooksWithoutBorders extends JavaPlugin {
|
||||
getInstance().playerLetterIndex = new HashMap<>();
|
||||
}
|
||||
|
||||
@Override
|
||||
public void reloadConfig() {
|
||||
this.configuration = StargateYamlConfiguration.loadConfiguration(this, true);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void saveConfig() {
|
||||
StargateYamlConfiguration.saveConfiguration(this, this.configuration);
|
||||
}
|
||||
|
||||
@Override
|
||||
@NotNull
|
||||
public FileConfiguration getConfig() {
|
||||
if (this.configuration == null) {
|
||||
this.reloadConfig();
|
||||
}
|
||||
return this.configuration;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onEnable() {
|
||||
FileConfiguration config = this.getConfig();
|
||||
config.options().copyDefaults(true);
|
||||
this.saveDefaultConfig();
|
||||
booksWithoutBorders = this;
|
||||
ConfigHelper.saveDefaults(this);
|
||||
|
||||
//Migrate from an earlier configuration file syntax if necessary
|
||||
if (this.configuration.getString("Options.Save_Books_in_Yaml_Format") != null) {
|
||||
ConfigHelper.migrateConfig(this);
|
||||
}
|
||||
|
||||
//Get plugin info
|
||||
PluginDescriptionFile pluginDescriptionFile = this.getDescription();
|
||||
@@ -222,7 +247,7 @@ public class BooksWithoutBorders extends JavaPlugin {
|
||||
stringFormatter.setErrorColor(ChatColor.of("#FF84A9"));
|
||||
FormatBuilder.setStringFormatter(stringFormatter);
|
||||
|
||||
booksWithoutBorders = this;
|
||||
|
||||
playerBooksList = new HashMap<>();
|
||||
playerLetterIndex = new HashMap<>();
|
||||
booksWithoutBordersConfig = new BwBConfig(this, translator);
|
||||
|
@@ -272,7 +272,8 @@ public class BwBConfig {
|
||||
* Saves the config
|
||||
*/
|
||||
public void saveConfigValues() {
|
||||
Configuration config = BooksWithoutBorders.getInstance().getConfig();
|
||||
BooksWithoutBorders instance = BooksWithoutBorders.getInstance();
|
||||
Configuration config = instance.getConfig();
|
||||
config.set(ConfigOption.MAX_DUPLICATES.getConfigNode(), this.bookDuplicateLimit);
|
||||
config.set(ConfigOption.TITLE_AUTHOR_SEPARATOR.getConfigNode(), this.titleAuthorSeparator);
|
||||
config.set(ConfigOption.LORE_LINE_SEPARATOR.getConfigNode(), this.loreSeparator);
|
||||
@@ -300,7 +301,7 @@ public class BwBConfig {
|
||||
config.set(ConfigOption.AUTHOR_ONLY_SAVE.getConfigNode(), this.authorOnlySave);
|
||||
config.set(ConfigOption.CHANGE_GENERATION_ON_COPY.getConfigNode(), this.changeGenerationOnCopy);
|
||||
config.set(ConfigOption.ALLOW_PREVENT_ADMIN_DECRYPTION.getConfigNode(), this.allowPreventAdminDecryption);
|
||||
BooksWithoutBorders.getInstance().saveConfig();
|
||||
instance.saveConfig();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -309,8 +310,9 @@ public class BwBConfig {
|
||||
* @return <p>True if the config was loaded successfully</p>
|
||||
*/
|
||||
public boolean loadConfig() {
|
||||
BooksWithoutBorders.getInstance().reloadConfig();
|
||||
Configuration config = BooksWithoutBorders.getInstance().getConfig();
|
||||
BooksWithoutBorders instance = BooksWithoutBorders.getInstance();
|
||||
instance.reloadConfig();
|
||||
Configuration config = instance.getConfig();
|
||||
try {
|
||||
this.bookDuplicateLimit = config.getInt(ConfigOption.MAX_DUPLICATES.getConfigNode(),
|
||||
(Integer) ConfigOption.MAX_DUPLICATES.getDefaultValue());
|
||||
@@ -327,7 +329,7 @@ public class BwBConfig {
|
||||
this.enableBookshelfPeeking = getBoolean(config, ConfigOption.ENABLE_BOOKSHELF_PEEKING);
|
||||
this.useRealEncryption = getBoolean(config, ConfigOption.USE_REAL_ENCRYPTION);
|
||||
this.allowPreventAdminDecryption = getBoolean(config, ConfigOption.ALLOW_PREVENT_ADMIN_DECRYPTION);
|
||||
String language = config.getString("language", "en");
|
||||
String language = getString(config, ConfigOption.LANGUAGE);
|
||||
this.translator.loadLanguages(BooksWithoutBorders.getInstance().getDataFolder(), "en", language);
|
||||
|
||||
//Convert string into material
|
||||
|
@@ -10,82 +10,87 @@ public enum ConfigOption {
|
||||
/**
|
||||
* The max duplicates of a book that can be saved
|
||||
*/
|
||||
MAX_DUPLICATES("Options.Max_Number_of_Duplicates", 5),
|
||||
MAX_DUPLICATES("limit.maxDuplicates", 5),
|
||||
|
||||
/**
|
||||
* The separator used to separate book title and book author
|
||||
*/
|
||||
TITLE_AUTHOR_SEPARATOR("Options.Title-Author_Separator", ","),
|
||||
TITLE_AUTHOR_SEPARATOR("separator.titleAuthor", ","),
|
||||
|
||||
/**
|
||||
* The separator used to specify a new line in an item's lore
|
||||
*/
|
||||
LORE_LINE_SEPARATOR("Options.Lore_line_separator", "~"),
|
||||
LORE_LINE_SEPARATOR("separator.loreLine", "~"),
|
||||
|
||||
/**
|
||||
* The books given to new players when they first join
|
||||
*/
|
||||
BOOKS_FOR_NEW_PLAYERS("Options.Books_for_new_players", "[]"),
|
||||
BOOKS_FOR_NEW_PLAYERS("firstJoin.booksToGive", "[]"),
|
||||
|
||||
/**
|
||||
* The message to display to new players when they first join
|
||||
*/
|
||||
MESSAGE_FOR_NEW_PLAYERS("Options.Message_for_new_players", ""),
|
||||
MESSAGE_FOR_NEW_PLAYERS("firstJoin.welcomeMessage", ""),
|
||||
|
||||
/**
|
||||
* The item type used to pay for book copying
|
||||
*/
|
||||
PRICE_ITEM_TYPE("Options.Price_to_create_book.Item_type", ""),
|
||||
PRICE_ITEM_TYPE("bookPrice.itemType", ""),
|
||||
|
||||
/**
|
||||
* The amount of items used to pay for book copying
|
||||
*/
|
||||
PRICE_QUANTITY("Options.Price_to_create_book.Required_quantity", 0.0),
|
||||
PRICE_QUANTITY("bookPrice.quantity", 0.0),
|
||||
|
||||
/**
|
||||
* Whether admins should be able to decrypt books for all groups
|
||||
*/
|
||||
ADMIN_AUTO_DECRYPT("Options.Admin_Auto_Decrypt", false),
|
||||
ADMIN_AUTO_DECRYPT("encryption.allowAdminBypass", false),
|
||||
|
||||
/**
|
||||
* Whether only the book author should be able to copy a book
|
||||
*/
|
||||
AUTHOR_ONLY_COPY("Options.Author_Only_Copy", false),
|
||||
AUTHOR_ONLY_COPY("authorRestricted.copy", false),
|
||||
|
||||
/**
|
||||
* Whether only the book author should be able to unsign a book
|
||||
*/
|
||||
AUTHOR_ONLY_UNSIGN("Options.Author_Only_Unsign", false),
|
||||
AUTHOR_ONLY_UNSIGN("authorRestricted.unsign", false),
|
||||
|
||||
/**
|
||||
* Whether a player can only save their own books with /saveBook
|
||||
*/
|
||||
AUTHOR_ONLY_SAVE("Options.Author_Only_Save", false),
|
||||
AUTHOR_ONLY_SAVE("authorRestricted.save", false),
|
||||
|
||||
/**
|
||||
* Whether to turn Original into Copy when copying books
|
||||
*/
|
||||
CHANGE_GENERATION_ON_COPY("Options.Change_Generation_On_Copy", false),
|
||||
CHANGE_GENERATION_ON_COPY("functionality.changeBookGenerationOnCopy", false),
|
||||
|
||||
/**
|
||||
* Whether to automatically format every signed book
|
||||
*/
|
||||
FORMAT_AFTER_SIGNING("Options.Format_Book_After_Signing", false),
|
||||
FORMAT_AFTER_SIGNING("functionality.formatBookOnSigning", true),
|
||||
|
||||
/**
|
||||
* Whether hitting a bookshelf should display information about the contained books
|
||||
*/
|
||||
ENABLE_BOOKSHELF_PEEKING("Options.Enable_Book_Peeking", true),
|
||||
ENABLE_BOOKSHELF_PEEKING("functionality.enableBookPeeking", true),
|
||||
|
||||
/**
|
||||
* Whether to use real AES encryption instead of storing garbled book text, while the full plaintext is stored in a file
|
||||
*/
|
||||
USE_REAL_ENCRYPTION("Options.Use_Real_Encryption", false),
|
||||
USE_REAL_ENCRYPTION("encryption.useRealEncryption", false),
|
||||
|
||||
/**
|
||||
* Whether to allow disabling admin encryption for a real encrypted book
|
||||
*/
|
||||
ALLOW_PREVENT_ADMIN_DECRYPTION("Options.Allow_Prevent_Admin_Decryption", false),
|
||||
ALLOW_PREVENT_ADMIN_DECRYPTION("encryption.allowAdminBypassBlocking", false),
|
||||
|
||||
/**
|
||||
* The language to load from strings.yml
|
||||
*/
|
||||
LANGUAGE("language", "en"),
|
||||
;
|
||||
|
||||
private final String configNode;
|
||||
|
18
src/main/resources/config-migrations.txt
Normal file
18
src/main/resources/config-migrations.txt
Normal file
@@ -0,0 +1,18 @@
|
||||
Options.Language=language
|
||||
Options.Title-Author_Separator=separator.titleAuthor
|
||||
Options.Lore_line_separator=separator.loreLine
|
||||
Options.Price_to_create_book.Item_type=bookPrice.itemType
|
||||
Options.Price_to_create_book.Required_quantity=bookPrice.quantity
|
||||
Options.Author_Only_Copy=authorRestricted.copy
|
||||
Options.Author_Only_Unsign=authorRestricted.unsign
|
||||
Options.Author_Only_Save=authorRestricted.save
|
||||
Options.Books_for_new_players=firstJoin.booksToGive
|
||||
Options.Message_for_new_players=firstJoin.welcomeMessage
|
||||
Options.Admin_Auto_Decrypt=encryption.allowAdminBypass
|
||||
Options.Use_Real_Encryption=encryption.useRealEncryption
|
||||
Options.Allow_Prevent_Admin_Decryption=encryption.allowAdminBypassBlocking
|
||||
Options.Max_Number_of_Duplicates=limit.maxDuplicates
|
||||
Options.Format_Book_After_Signing=functionality.formatBookOnSigning
|
||||
Options.Change_Generation_On_Copy=functionality.changeBookGenerationOnCopy
|
||||
Options.Enable_Book_Peeking=functionality.enableBookPeeking
|
||||
Options.Save_Books_in_Yaml_Format=
|
@@ -1,45 +1,103 @@
|
||||
Options:
|
||||
# The language to use. Only "en" is built-in, but custom languages can be added
|
||||
Language: "en"
|
||||
# The maximum number of duplicates of a saved book allowed
|
||||
Max_Number_of_Duplicates: 5
|
||||
# Books Without Borders configuration file
|
||||
|
||||
# The language to use. Only "en" is built-in, but custom languages can be added.
|
||||
language: "en"
|
||||
|
||||
# +------------------------------------+ #
|
||||
# | Limits | #
|
||||
# +------------------------------------+ #
|
||||
limit:
|
||||
# The maximum number of duplicates of a saved book allowed. Note that duplicates are only used for storing unsigned
|
||||
# books so players can save drafts of their book. Duplicates are not allowed for signed books.
|
||||
maxDuplicates: 5
|
||||
|
||||
# +----------------------------------------------------+ #
|
||||
# | Separators for parsing | #
|
||||
# +----------------------------------------------------+ #
|
||||
separator:
|
||||
# The separator used to separate the book title and the book author. While this is a ',' by default for backwards
|
||||
# compatibility, a rarely used character like '¤' is better to prevent restrictions on book titles.
|
||||
Title-Author_Separator: ","
|
||||
# The separator used to denote a new line in the book/item lore
|
||||
Lore_line_separator: "~"
|
||||
# A list of books given to new players the first time they join the server
|
||||
Books_for_new_players: [ ]
|
||||
# An optional message displayed to new players the first time they join the server
|
||||
Message_for_new_players: ""
|
||||
# Price settings for book copying
|
||||
Price_to_create_book:
|
||||
# The item type used as currency for copying books. Use "Economy" to use money instead of items
|
||||
Item_type: ""
|
||||
titleAuthor: ","
|
||||
|
||||
# The separator used to denote a new line in the book/item lore.
|
||||
loreLine: "~"
|
||||
|
||||
# +---------------------------------------------------+ #
|
||||
# | New player first join | #
|
||||
# +---------------------------------------------------+ #
|
||||
firstJoin:
|
||||
# A list of books given to new players the first time they join the server.
|
||||
booksToGive: [ ]
|
||||
|
||||
# An optional message displayed to new players the first time they join the server.
|
||||
welcomeMessage: ""
|
||||
|
||||
# +-------------------------------------------------+ #
|
||||
# | Book creation price | #
|
||||
# +-------------------------------------------------+ #
|
||||
# You can set the price with the "/setBookPrice" command.
|
||||
# +-------------------------------------------------+ #
|
||||
bookPrice:
|
||||
# The item type used as currency for copying books. Use "Economy" to use money instead of items.
|
||||
itemType: ""
|
||||
|
||||
# The quantity of currency required to pay for each book produced
|
||||
Required_quantity: 0
|
||||
# Whether any admin can decrypt any book regardless of the group it was encrypted for
|
||||
Admin_Auto_Decrypt: false
|
||||
# Whether to only allow the author of a book to create copies
|
||||
Author_Only_Copy: false
|
||||
# Whether to only allow the author of a book to unsign it
|
||||
Author_Only_Unsign: false
|
||||
# Whether to only allow saving a player's own books with /saveBook
|
||||
Author_Only_Save: false
|
||||
# Whether to automatically format every book when it's signed
|
||||
Format_Book_After_Signing: false
|
||||
# Whether to display "COPY" or "COPY_OF_COPY" instead of "ORIGINAL" when a book is copied. This also uses the
|
||||
# vanilla behavior where a copy of a copy cannot be copied further.
|
||||
Change_Generation_On_Copy: false
|
||||
# This will be either the economy cost, or the number of items. Decimals are supported, but will be ignored for item
|
||||
# amount.
|
||||
quantity: 0
|
||||
|
||||
# +---------------------------------------------------------------------+ #
|
||||
# | Enable/Disable author-only restrictions | #
|
||||
# +---------------------------------------------------------------------+ #
|
||||
# These options can be useful for survival gameplay, in order to allow some functionality, but still restrict actions to
|
||||
# players' own books.
|
||||
# +---------------------------------------------------------------------+ #
|
||||
authorRestricted:
|
||||
# Whether to only allow the author of a book to create copies.
|
||||
copy: false
|
||||
|
||||
# Whether to only allow the author of a book to unsign it.
|
||||
unsign: false
|
||||
|
||||
# Whether to only allow saving a player's own books with "/saveBook".
|
||||
save: false
|
||||
|
||||
# +----------------------------------------------------------+ #
|
||||
# | Enable/Disable functionality | #
|
||||
# +----------------------------------------------------------+ #
|
||||
functionality:
|
||||
# Whether to automatically format every book when it's signed, if the player has permission.
|
||||
# Formatting is automatically reverted when a book is unsigned, so having this on should generally not cause trouble.
|
||||
formatBookOnSigning: true
|
||||
|
||||
# Whether to set the generation to "COPY" or "COPY_OF_COPY" instead of "ORIGINAL" when a book is copied. This also
|
||||
# uses the vanilla behavior where a copy of a copy or tattered book cannot be copied further.
|
||||
changeBookGenerationOnCopy: false
|
||||
|
||||
# Whether to enable hitting a chiseled bookshelf while sneaking to see the shelf's contents.
|
||||
Enable_Book_Peeking: true
|
||||
enableBookPeeking: true
|
||||
|
||||
# +-------------------------------------------------+ #
|
||||
# | Encryption behavior | #
|
||||
# +-------------------------------------------------+ #
|
||||
encryption:
|
||||
# Whether any admin can decrypt any book regardless of the group it was encrypted for, and decrypt normally encrypted
|
||||
# books without having to supply a password.
|
||||
allowAdminBypass: false
|
||||
|
||||
# Whether to use true AES encryption when encrypting and decrypting books. While the hashed password used for
|
||||
# encryption is still stored in the book file, the readable contents of the book are not. Admin decrypt can be used to
|
||||
# peek at books, if an admin gets a hold of a book with the same title and author, but only the encrypted AES cypher text is stored in the book.
|
||||
# peek at books, if an admin gets a hold of a book with the same title and author. Only the encrypted AES cypher
|
||||
# text is stored in the book, so admins cannot see the contents by looking in the stored encrypted file on the server.
|
||||
#
|
||||
# If "allowAdminBypassBlocking" is enabled, admin decryption can be disabled for a book
|
||||
# when using the "/encryptbook" command.
|
||||
#
|
||||
# Note that real encryption might alter, corrupt or lose a book's contents, so don't use real encryption with books
|
||||
# that have no backup in in-game book form or saved book form.
|
||||
Use_Real_Encryption: false
|
||||
useRealEncryption: false
|
||||
|
||||
# Whether to allow players to specifically disable admin decryption for a real encrypted book. This is only available
|
||||
# when real encryption is enabled. It allows a player to prevent the storage of the encryption key in the plugin
|
||||
# folder, meaning that the only way to decrypt the book is to provide the correct key. THIS IS A DANGEROUS OPTION!
|
||||
Allow_Prevent_Admin_Decryption: false
|
||||
allowAdminBypassBlocking: false
|
Reference in New Issue
Block a user