private void updateContainerInfo() {
        try {
            int total = ImageUtils.calculatePossibleDataSpace(new File(edContainerFile.getText()), edBoardCode.getText());
            int used = EncryptionProvider.SHA_256_HASH_SIZE_BYTES * 2 + "{ \"timestamp\": 0000000000000, \"postText\": \"\" }".length() + txtPostText.getText().length();
            File attach = new File(edAttachFile.getText());
            if (attach.exists()) {
                used += attach.length();
            }

            lblCapacity.setText(String.format("%s bytes total, %s used", total, used));

            pbCapacity.setMaximum(total);
            pbCapacity.setValue(used);
        } catch (IOException ex) {
            lblCapacity.setText("invalid container file");
            pbCapacity.setMaximum(0);
            pbCapacity.setValue(0);
        }
    }