renaming the fork to PrivateBin

pull/44/head
El RIDO 8 years ago
parent 6a663ba07f
commit 79509ad48a

@ -33,10 +33,10 @@
* for simpler maintenance the functions were grouped into objects: zerobin (display logic, event handling), filter (compression,
encryption), i18n (translation, counterpart of i18n.php) and helper (stateless utilities)
* Wiki pages were added to address common topics:
* [Upgrading from ZeroBin 0.19 Alpha](https://github.com/elrido/ZeroBin/wiki/Upgrading-from-ZeroBin-0.19-Alpha)
* [ZeroBin Directory of public servers](https://github.com/elrido/ZeroBin/wiki/ZeroBin-Directory)
* [Translation](https://github.com/elrido/ZeroBin/wiki/Translation)
* [Templates](https://github.com/elrido/ZeroBin/wiki/Templates)
* [Upgrading from ZeroBin 0.19 Alpha](https://github.com/PrivateBin/PrivateBin/wiki/Upgrading-from-ZeroBin-0.19-Alpha)
* [Directory of public PrivateBin servers](https://github.com/PrivateBin/PrivateBin/wiki/PrivateBin-Directory)
* [Translation](https://github.com/PrivateBin/PrivateBin/wiki/Translation)
* [Templates](https://github.com/PrivateBin/PrivateBin/wiki/Templates)
* **0.20 (2015-09-03)**:
* ADDED: Password protected pastes (optional)
* ADDED: configuration options for highlighting, password, discussions, expiration times, rate limiting

@ -53,7 +53,7 @@ languageselection = false
; the pastes encryption key
; urlshortener = "https://shortener.example.com/api?link="
; stay compatible with ZeroBin Alpha 0.19, less secure
; stay compatible with PrivateBin Alpha 0.19, less secure
; if enabled will use base64.js version 1.7 instead of 2.1.9 and sha1 instead of
; sha256 in HMAC for the deletion token
zerobincompatibility = false
@ -100,24 +100,24 @@ dir = PATH "data"
[model]
; name of data model class to load and directory for storage
; the default model "zerobin_data" stores everything in the filesystem
class = zerobin_data
; the default model "privatebin_data" stores everything in the filesystem
class = privatebin_data
[model_options]
dir = PATH "data"
;[model]
; example of DB configuration for MySQL
;class = zerobin_db
;class = privatebin_db
;[model_options]
;dsn = "mysql:host=localhost;dbname=zerobin;charset=UTF8"
;tbl = "zerobin_" ; table prefix
;usr = "zerobin"
;dsn = "mysql:host=localhost;dbname=privatebin;charset=UTF8"
;tbl = "privatebin_" ; table prefix
;usr = "privatebin"
;pwd = "Z3r0P4ss"
;opt[12] = true ; PDO::ATTR_PERSISTENT
;[model]
; example of DB configuration for SQLite
;class = zerobin_db
;class = privatebin_db
;[model_options]
;dsn = "sqlite:" PATH "data/db.sq3"
;usr = null

@ -1,4 +1,4 @@
/* ZeroBin 0.22 - http://sebsauvage.net/wiki/doku.php?id=php:zerobin */
/* PrivateBin 0.22 - https://github.com/PrivateBin/PrivateBin */
body {

@ -1,4 +1,4 @@
/* ZeroBin 0.22 - http://sebsauvage.net/wiki/doku.php?id=php:zerobin */
/* PrivateBin 0.22 - https://github.com/PrivateBin/PrivateBin */
/* CSS Reset from YUI 3.4.1 (build 4118) - Copyright 2011 Yahoo! Inc. All rights reserved.

@ -18,6 +18,6 @@ $ sudo pear install phpdoc/phpDocumentor
To generate the documentation, change into the main directory and run phpdoc:
```console
$ cd ZeroBin
$ cd PrivateBin
$ phpdoc -d lib/ -t doc/
```

@ -2,10 +2,10 @@
"en": "de",
"Paste does not exist, has expired or has been deleted.":
"Diesen Text gibt es nicht, er ist abgelaufen oder wurde gelöscht.",
"ZeroBin requires php 5.2.6 or above to work. Sorry.":
"ZeroBin benötigt PHP 5.2.6 oder höher, um zu funktionieren. Sorry.",
"ZeroBin requires configuration section [%s] to be present in configuration file.":
"ZeroBin benötigt den Konfigurationsabschnitt [%s] in der Konfigurationsdatei um zu funktionieren.",
"PrivateBin requires php 5.2.6 or above to work. Sorry.":
"PrivateBin benötigt PHP 5.2.6 oder höher, um zu funktionieren. Sorry.",
"PrivateBin requires configuration section [%s] to be present in configuration file.":
"PrivateBin benötigt den Konfigurationsabschnitt [%s] in der Konfigurationsdatei um zu funktionieren.",
"Please wait %d seconds between each post.":
"Bitte warte %d Sekunden zwischen dem Absenden.",
"Paste is limited to %s of encrypted data.":
@ -26,15 +26,15 @@
"Falscher Lösch-Code. Text wurde nicht gelöscht.",
"Paste was properly deleted.":
"Text wurde erfolgreich gelöscht.",
"ZeroBin": "ZeroBin",
"ZeroBin is a minimalist, opensource online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href=\"https://github.com/elrido/ZeroBin/wiki\">project page</a>.":
"ZeroBin ist ein minimalistischer, quelloffener \"Pastebin\"-artiger Dienst, bei dem der Server keinerlei Kenntnis der Inhalte hat. Die Daten werden <i>im Browser</i> mit 256 Bit AES ver- und entschlüsselt. Weitere Informationen sind auf der <a href=\"https://github.com/elrido/ZeroBin/wiki\">Projektseite</a> zu finden.",
"PrivateBin": "PrivateBin",
"PrivateBin is a minimalist, opensource online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href=\"https://github.com/elrido/PrivateBin/wiki\">project page</a>.":
"PrivateBin ist ein minimalistischer, quelloffener \"Pastebin\"-artiger Dienst, bei dem der Server keinerlei Kenntnis der Inhalte hat. Die Daten werden <i>im Browser</i> mit 256 Bit AES ver- und entschlüsselt. Weitere Informationen sind auf der <a href=\"https://github.com/elrido/PrivateBin/wiki\">Projektseite</a> zu finden.",
"Because ignorance is bliss":
"Unwissenheit ist ein Segen",
"Javascript is required for ZeroBin to work.<br />Sorry for the inconvenience.":
"Javascript ist eine Voraussetzung, um ZeroBin zu nutzen.<br />Bitte entschuldige die Unannehmlichkeiten.",
"ZeroBin requires a modern browser to work.":
"ZeroBin setzt einen modernen Browser voraus, um funktionieren zu können.",
"Javascript is required for PrivateBin to work.<br />Sorry for the inconvenience.":
"Javascript ist eine Voraussetzung, um PrivateBin zu nutzen.<br />Bitte entschuldige die Unannehmlichkeiten.",
"PrivateBin requires a modern browser to work.":
"PrivateBin setzt einen modernen Browser voraus, um funktionieren zu können.",
"Still using Internet Explorer? Do yourself a favor, switch to a modern browser:":
"Du benutzt immer noch den Internet Explorer? Tu Dir einen Gefallen und wechsle zu einem moderneren Browser:",
"New":

@ -2,10 +2,10 @@
"en": "fr",
"Paste does not exist, has expired or has been deleted.":
"Le paste n'existe pas, a expiré, ou a été supprimé.",
"ZeroBin requires php 5.2.6 or above to work. Sorry.":
"Désolé, ZeroBin nécessite php 5.2.6 ou supérieur pour fonctionner.",
"ZeroBin requires configuration section [%s] to be present in configuration file.":
"ZeroBin a besoin de la section de configuration [%s] dans le fichier de configuration pour fonctionner.",
"PrivateBin requires php 5.2.6 or above to work. Sorry.":
"Désolé, PrivateBin nécessite php 5.2.6 ou supérieur pour fonctionner.",
"PrivateBin requires configuration section [%s] to be present in configuration file.":
"PrivateBin a besoin de la section de configuration [%s] dans le fichier de configuration pour fonctionner.",
"Please wait %d seconds between each post.":
"Merci d'attendre %d secondes entre chaque publication.",
"Paste is limited to %s of encrypted data.":
@ -26,15 +26,15 @@
"Jeton de suppression incorrect. Le paste n'a pas été supprimé.",
"Paste was properly deleted.":
"Le paste a été correctement supprimé.",
"ZeroBin": "ZeroBin",
"ZeroBin is a minimalist, opensource online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href=\"https://github.com/elrido/ZeroBin/wiki\">project page</a>.":
"Zerobin est un 'pastebin' (ou gestionnaire d'extraits de texte et de code source) minimaliste et open source, dans lequel le serveur n'a aucune connaissance des données envoyées. Les données sont chiffrées/déchiffrées <i>dans le navigateur</i> par un chiffrage AES 256 bits. Plus d'informations sur <a href=\"https://github.com/elrido/ZeroBin/wiki\">la page du projet</a>.",
"PrivateBin": "PrivateBin",
"PrivateBin is a minimalist, opensource online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href=\"https://github.com/elrido/PrivateBin/wiki\">project page</a>.":
"PrivateBin est un 'pastebin' (ou gestionnaire d'extraits de texte et de code source) minimaliste et open source, dans lequel le serveur n'a aucune connaissance des données envoyées. Les données sont chiffrées/déchiffrées <i>dans le navigateur</i> par un chiffrage AES 256 bits. Plus d'informations sur <a href=\"https://github.com/elrido/PrivateBin/wiki\">la page du projet</a>.",
"Because ignorance is bliss":
"Parce que l'ignorance est le bonheur",
"Javascript is required for ZeroBin to work.<br />Sorry for the inconvenience.":
"Javascript est requis pour faire fonctionner ZeroBin. <br />Désolé pour cet inconvénient.",
"ZeroBin requires a modern browser to work.":
"ZeroBin nécessite un navigateur moderne pour fonctionner.",
"Javascript is required for PrivateBin to work.<br />Sorry for the inconvenience.":
"Javascript est requis pour faire fonctionner PrivateBin. <br />Désolé pour cet inconvénient.",
"PrivateBin requires a modern browser to work.":
"PrivateBin nécessite un navigateur moderne pour fonctionner.",
"Still using Internet Explorer? Do yourself a favor, switch to a modern browser:":
"Encore sur Internet Explorer ? Faites-vous une faveur, passez à un navigateur moderne :",
"New":

@ -2,10 +2,10 @@
"en": "pl",
"Paste does not exist, has expired or has been deleted.":
"Wklejka nie istnieje, wygasła albo została usunięta.",
"ZeroBin requires php 5.2.6 or above to work. Sorry.":
"ZeroBin wymaga PHP w wersji 5.2.6 lub nowszej, sorry.",
"ZeroBin requires configuration section [%s] to be present in configuration file.":
"ZeroBin wymaga obecności sekcji [%s] w pliku konfiguracyjnym.",
"PrivateBin requires php 5.2.6 or above to work. Sorry.":
"PrivateBin wymaga PHP w wersji 5.2.6 lub nowszej, sorry.",
"PrivateBin requires configuration section [%s] to be present in configuration file.":
"PrivateBin wymaga obecności sekcji [%s] w pliku konfiguracyjnym.",
"Please wait %d seconds between each post.":
"Poczekaj %d sekund pomiędzy każdą wklejką.",
"Paste is limited to %s of encrypted data.":
@ -26,15 +26,15 @@
"Nieprawidłowy token usuwania. Wklejka nie została usunięta.",
"Paste was properly deleted.":
"Wklejka usunięta poprawnie.",
"ZeroBin": "ZeroBin",
"ZeroBin is a minimalist, opensource online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href=\"https://github.com/elrido/ZeroBin/wiki\">project page</a>.":
"ZeroBin jest minimalistycznym, otwartoźródłowym serwisem typu pastebin, w którym serwer nie ma jakichkolwiek informacji o tym, co jest wklejane. Dane są szyfrowane i deszyfrowane <i>w przeglądarce</i> z użyciem 256-bitowego klucza AES. Więcej informacji na <a href=\"https://github.com/elrido/ZeroBin/wiki\">stronie projektu</a>.",
"PrivateBin": "PrivateBin",
"PrivateBin is a minimalist, opensource online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href=\"https://github.com/elrido/PrivateBin/wiki\">project page</a>.":
"PrivateBin jest minimalistycznym, otwartoźródłowym serwisem typu pastebin, w którym serwer nie ma jakichkolwiek informacji o tym, co jest wklejane. Dane są szyfrowane i deszyfrowane <i>w przeglądarce</i> z użyciem 256-bitowego klucza AES. Więcej informacji na <a href=\"https://github.com/elrido/PrivateBin/wiki\">stronie projektu</a>.",
"Because ignorance is bliss":
"Ponieważ ignorancja jest cnotą",
"Javascript is required for ZeroBin to work.<br />Sorry for the inconvenience.":
"Do działania ZeroBina jest wymagany JavaScript. Przepraszamy za tę niedogodność.",
"ZeroBin requires a modern browser to work.":
"ZeroBin wymaga do działania nowoczesnej przeglądarki.",
"Javascript is required for PrivateBin to work.<br />Sorry for the inconvenience.":
"Do działania PrivateBina jest wymagany JavaScript. Przepraszamy za tę niedogodność.",
"PrivateBin requires a modern browser to work.":
"PrivateBin wymaga do działania nowoczesnej przeglądarki.",
"Still using Internet Explorer? Do yourself a favor, switch to a modern browser:":
"Cały czas używasz Internet Explorera? Zrób sobie przysługę, przesiądź się na nowoczesną przeglądarkę:",
"New":

@ -2,10 +2,10 @@
"en": "sl",
"Paste does not exist, has expired or has been deleted.":
"Prilepek ne obstaja, mu je potekla življenjska doba, ali pa je izbrisan.",
"ZeroBin requires php 5.2.6 or above to work. Sorry.":
"Oprosti, ZeroBin za delovanje potrebuje vsaj php 5.2.6.",
"ZeroBin requires configuration section [%s] to be present in configuration file.":
"ZeroBin potrebuje sekcijo konfiguracij [%s] v konfiguracijski datoteki.",
"PrivateBin requires php 5.2.6 or above to work. Sorry.":
"Oprosti, PrivateBin za delovanje potrebuje vsaj php 5.2.6.",
"PrivateBin requires configuration section [%s] to be present in configuration file.":
"PrivateBin potrebuje sekcijo konfiguracij [%s] v konfiguracijski datoteki.",
"Please wait %d seconds between each post.":
"Prosim počakaj vsaj %d sekund pred vsako naslednjo objavo.",
"Paste is limited to %s of encrypted data.":
@ -26,15 +26,15 @@
"Napačen token za izbris. Prilepek ni bil izbrisan..",
"Paste was properly deleted.":
"Prilepek je uspešno izbrisan.",
"ZeroBin": "ZeroBin",
"ZeroBin is a minimalist, opensource online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href=\"https://github.com/elrido/ZeroBin/wiki\">project page</a>.":
"Zerobin je minimalističen, odprtokodni spletni 'pastebin', kjer server ne ve ničesar o prilepljenih podatkih. Podatki so zakodirani/odkodirani <i>v brskalniku</i> z uporabo 256 bitnega AES. Več informacij na < href=\"https://github.com/elrido/ZeroBin/wiki\">spletni strani projekta.</a>.",
"PrivateBin": "PrivateBin",
"PrivateBin is a minimalist, opensource online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href=\"https://github.com/elrido/PrivateBin/wiki\">project page</a>.":
"PrivateBin je minimalističen, odprtokodni spletni 'pastebin', kjer server ne ve ničesar o prilepljenih podatkih. Podatki so zakodirani/odkodirani <i>v brskalniku</i> z uporabo 256 bitnega AES. Več informacij na < href=\"https://github.com/elrido/PrivateBin/wiki\">spletni strani projekta.</a>.",
"Because ignorance is bliss":
"Ker kar ne veš ne boli.",
"Javascript is required for ZeroBin to work.<br />Sorry for the inconvenience.":
"Da ZeroBin deluje, moraš vklopiti Javascript.<br />Oprosti za povročene nevšečnosti.",
"ZeroBin requires a modern browser to work.":
"ZeroBin za svoje delovanje potrebuje moderen brskalnik.",
"Javascript is required for PrivateBin to work.<br />Sorry for the inconvenience.":
"Da PrivateBin deluje, moraš vklopiti Javascript.<br />Oprosti za povročene nevšečnosti.",
"PrivateBin requires a modern browser to work.":
"PrivateBin za svoje delovanje potrebuje moderen brskalnik.",
"Still using Internet Explorer? Do yourself a favor, switch to a modern browser:":
"Še vedno uporabljaš Internet Explorer? Naredi si uslugo, preklopi na moderen brskalnik:",
"New":

@ -2,10 +2,10 @@
"en": "zh",
"Paste does not exist, has expired or has been deleted.":
"粘贴不存在,已过期或者已被删除。",
"ZeroBin requires php 5.2.6 or above to work. Sorry.":
"ZeroBin需要工作于PHP 5.2.6及以上版本,抱歉。",
"ZeroBin requires configuration section [%s] to be present in configuration file.":
"ZeroBin需要设置配置文件中 [%s] 的部分。",
"PrivateBin requires php 5.2.6 or above to work. Sorry.":
"PrivateBin需要工作于PHP 5.2.6及以上版本,抱歉。",
"PrivateBin requires configuration section [%s] to be present in configuration file.":
"PrivateBin需要设置配置文件中 [%s] 的部分。",
"Please wait %d seconds between each post.":
"每 %d 秒只能粘贴一次。",
"Paste is limited to %s of encrypted data.":
@ -26,15 +26,15 @@
"错误的删除token粘贴没有被删除。",
"Paste was properly deleted.":
"粘贴已被正确删除。",
"ZeroBin": "ZeroBin",
"ZeroBin is a minimalist, opensource online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href=\"https://github.com/elrido/ZeroBin/wiki\">project page</a>.":
"ZeroBin是一个极简开源对粘贴内容毫不知情的在线粘贴板数据<i>在浏览器内</i>进行AES-256加密。更多信息请查看<a href=\"https://github.com/elrido/ZeroBin/wiki\">项目主页</a>。",
"PrivateBin": "PrivateBin",
"PrivateBin is a minimalist, opensource online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href=\"https://github.com/elrido/PrivateBin/wiki\">project page</a>.":
"PrivateBin是一个极简开源对粘贴内容毫不知情的在线粘贴板数据<i>在浏览器内</i>进行AES-256加密。更多信息请查看<a href=\"https://github.com/elrido/PrivateBin/wiki\">项目主页</a>。",
"Because ignorance is bliss":
"因为无知是福",
"Javascript is required for ZeroBin to work.<br />Sorry for the inconvenience.":
"ZeroBin需要JavaScript来进行加解密。<br />带来的不便敬请谅解。",
"ZeroBin requires a modern browser to work.":
"ZeroBin需要工作于现代化的浏览器。",
"Javascript is required for PrivateBin to work.<br />Sorry for the inconvenience.":
"PrivateBin需要JavaScript来进行加解密。<br />带来的不便敬请谅解。",
"PrivateBin requires a modern browser to work.":
"PrivateBin需要工作于现代化的浏览器。",
"Still using Internet Explorer? Do yourself a favor, switch to a modern browser:":
"还在使用Internet Explorer帮自己个忙换上一个现代化的浏览器",
"New":

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22
@ -15,4 +15,4 @@ define('PATH', '');
define('PUBLIC_PATH', dirname(__FILE__));
require PATH . 'lib/auto.php';
new zerobin;
new privatebin;

@ -1,9 +1,9 @@
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22
@ -481,7 +481,7 @@ $(function() {
}
};
var zerobin = {
var privatebin = {
/**
* headers to send in AJAX requests
*/
@ -695,7 +695,7 @@ $(function() {
headers: this.headers
})
.fail(function() {
zerobin.showError(i18n._('Could not delete the paste, it was not stored in burn after reading mode.'));
privatebin.showError(i18n._('Could not delete the paste, it was not stored in burn after reading mode.'));
});
helper.setMessage(this.remainingTime, i18n._(
'FOR YOUR EYES ONLY. Don\'t close this window, this message can\'t be displayed again.'
@ -842,44 +842,44 @@ $(function() {
{
if (data.status == 0)
{
zerobin.showStatus(i18n._('Comment posted.'), false);
privatebin.showStatus(i18n._('Comment posted.'), false);
$.ajax({
type: 'GET',
url: zerobin.scriptLocation() + '?' + zerobin.pasteID(),
url: privatebin.scriptLocation() + '?' + privatebin.pasteID(),
dataType: 'json',
headers: zerobin.headers,
headers: privatebin.headers,
success: function(data)
{
if (data.status == 0)
{
zerobin.displayMessages(zerobin.pageKey(), data);
privatebin.displayMessages(privatebin.pageKey(), data);
}
else if (data.status == 1)
{
zerobin.showError(i18n._('Could not refresh display: %s', data.message));
privatebin.showError(i18n._('Could not refresh display: %s', data.message));
}
else
{
zerobin.showError(i18n._('Could not refresh display: %s', i18n._('unknown status')));
privatebin.showError(i18n._('Could not refresh display: %s', i18n._('unknown status')));
}
}
})
.fail(function() {
zerobin.showError(i18n._('Could not refresh display: %s', i18n._('server error or not responding')));
privatebin.showError(i18n._('Could not refresh display: %s', i18n._('server error or not responding')));
});
}
else if (data.status == 1)
{
zerobin.showError(i18n._('Could not post comment: %s', data.message));
privatebin.showError(i18n._('Could not post comment: %s', data.message));
}
else
{
zerobin.showError(i18n._('Could not post comment: %s', i18n._('unknown status')));
privatebin.showError(i18n._('Could not post comment: %s', i18n._('unknown status')));
}
}
})
.fail(function() {
zerobin.showError(i18n._('Could not post comment: %s', i18n._('server error or not responding')));
privatebin.showError(i18n._('Could not post comment: %s', i18n._('server error or not responding')));
});
},
@ -926,7 +926,7 @@ $(function() {
reader.onload = (function(theFile)
{
return function(e) {
zerobin.sendDataContinue(
privatebin.sendDataContinue(
randomkey,
filter.cipher(randomkey, password, e.target.result),
filter.cipher(randomkey, password, theFile.name)
@ -983,38 +983,38 @@ $(function() {
success: function(data)
{
if (data.status == 0) {
zerobin.stateExistingPaste();
var url = zerobin.scriptLocation() + '?' + data.id + '#' + randomkey;
var deleteUrl = zerobin.scriptLocation() + '?pasteid=' + data.id + '&deletetoken=' + data.deletetoken;
zerobin.showStatus('', false);
zerobin.errorMessage.addClass('hidden');
privatebin.stateExistingPaste();
var url = privatebin.scriptLocation() + '?' + data.id + '#' + randomkey;
var deleteUrl = privatebin.scriptLocation() + '?pasteid=' + data.id + '&deletetoken=' + data.deletetoken;
privatebin.showStatus('', false);
privatebin.errorMessage.addClass('hidden');
$('#pastelink').html(
i18n._(
'Your paste is <a id="pasteurl" href="%s">%s</a> <span id="copyhint">(Hit [Ctrl]+[c] to copy)</span>',
url, url
) + zerobin.shortenUrl(url)
) + privatebin.shortenUrl(url)
);
$('#deletelink').html('<a href="' + deleteUrl + '">' + i18n._('Delete data') + '</a>');
zerobin.pasteResult.removeClass('hidden');
privatebin.pasteResult.removeClass('hidden');
// We pre-select the link so that the user only has to [Ctrl]+[c] the link.
helper.selectText('pasteurl');
zerobin.showStatus('', false);
zerobin.formatPaste(data_to_send.formatter, zerobin.message.val());
privatebin.showStatus('', false);
privatebin.formatPaste(data_to_send.formatter, privatebin.message.val());
}
else if (data.status==1)
{
zerobin.showError(i18n._('Could not create paste: %s', data.message));
privatebin.showError(i18n._('Could not create paste: %s', data.message));
}
else
{
zerobin.showError(i18n._('Could not create paste: %s', i18n._('unknown status')));
privatebin.showError(i18n._('Could not create paste: %s', i18n._('unknown status')));
}
}
})
.fail(function()
{
zerobin.showError(i18n._('Could not create paste: %s', i18n._('server error or not responding')));
privatebin.showError(i18n._('Could not create paste: %s', i18n._('server error or not responding')));
});
},
@ -1397,8 +1397,8 @@ $(function() {
/**
* main application start, called when DOM is fully loaded
* runs zerobin when translations were loaded
* runs privatebin when translations were loaded
*/
i18n.loadTranslations($.proxy(zerobin.init, zerobin));
i18n.loadTranslations($.proxy(privatebin.init, privatebin));
});

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22
@ -71,7 +71,7 @@ class configuration
'dir' => 'data',
),
'model' => array(
'class' => 'zerobin_data',
'class' => 'privatebin_data',
),
'model_options' => array(
'dir' => 'data',
@ -92,7 +92,7 @@ class configuration
$config = parse_ini_file($configFile, true);
foreach (array('main', 'model') as $section) {
if (!array_key_exists($section, $config)) {
throw new Exception(i18n::_('ZeroBin requires configuration section [%s] to be present in configuration file.', $section), 2);
throw new Exception(i18n::_('PrivateBin requires configuration section [%s] to be present in configuration file.', $section), 2);
}
}
}
@ -110,7 +110,7 @@ class configuration
continue;
}
// provide different defaults for database model
elseif ($section == 'model_options' && $this->_configuration['model']['class'] == 'zerobin_db')
elseif ($section == 'model_options' && $this->_configuration['model']['class'] == 'privatebin_db')
{
$values = array(
'dsn' => 'sqlite:' . PATH . 'data/db.sq3',
@ -228,7 +228,7 @@ class configuration
{
if (!array_key_exists($section, $this->_configuration))
{
throw new Exception(i18n::_('ZeroBin requires configuration section [%s] to be present in configuration file.', $section), 3);
throw new Exception(i18n::_('PrivateBin requires configuration section [%s] to be present in configuration file.', $section), 3);
}
return $this->_configuration[$section];
}

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22
@ -13,7 +13,7 @@
/**
* model
*
* Factory of ZeroBin instance models.
* Factory of PrivateBin instance models.
*/
class model
{
@ -27,7 +27,7 @@ class model
/**
* Data storage.
*
* @var zerobin_abstract
* @var privatebin_abstract
*/
private $_store = null;
@ -61,11 +61,16 @@ class model
{
if ($this->_store === null)
{
// added option to support old config file format
$model = str_replace(
'zerobin_', 'privatebin_',
$this->_conf->getKey('class', 'model')
);
$this->_store = forward_static_call(
array($this->_conf->getKey('class', 'model'), 'getInstance'),
array($model, 'getInstance'),
$this->_conf->getSection('model_options')
);
}
return $this->_store;
}
}
}

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22
@ -13,7 +13,7 @@
/**
* model_abstract
*
* Abstract model for ZeroBin objects.
* Abstract model for PrivateBin objects.
*/
abstract class model_abstract
{
@ -45,7 +45,7 @@ abstract class model_abstract
* Data storage.
*
* @access protected
* @var zerobin_abstract
* @var privatebin_abstract
*/
protected $_store;
@ -54,10 +54,10 @@ abstract class model_abstract
*
* @access public
* @param configuration $configuration
* @param zerobin_abstract $storage
* @param privatebin_abstract $storage
* @return void
*/
public function __construct(configuration $configuration, zerobin_abstract $storage)
public function __construct(configuration $configuration, privatebin_abstract $storage)
{
$this->_conf = $configuration;
$this->_store = $storage;

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22
@ -13,7 +13,7 @@
/**
* model_comment
*
* Model of a ZeroBin comment.
* Model of a PrivateBin comment.
*/
class model_comment extends model_abstract
{

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22
@ -13,7 +13,7 @@
/**
* model_paste
*
* Model of a ZeroBin paste.
* Model of a PrivateBin paste.
*/
class model_paste extends model_abstract
{
@ -27,7 +27,7 @@ class model_paste extends model_abstract
public function get()
{
$this->_data = $this->_store->read($this->getId());
if ($this->_data === false) throw new Exception(zerobin::GENERIC_ERROR, 64);
if ($this->_data === false) throw new Exception(privatebin::GENERIC_ERROR, 64);
// check if paste has expired and delete it if neccessary.
if (property_exists($this->_data->meta, 'expire_date'))
@ -35,7 +35,7 @@ class model_paste extends model_abstract
if ($this->_data->meta->expire_date < time())
{
$this->delete();
throw new Exception(zerobin::GENERIC_ERROR, 63);
throw new Exception(privatebin::GENERIC_ERROR, 63);
}
// We kindly provide the remaining time before expiration (in seconds)
$this->_data->meta->remaining_time = $this->_data->meta->expire_date - time();
@ -153,7 +153,7 @@ class model_paste extends model_abstract
*
* The token is the hmac of the pastes ID signed with the server salt.
* The paste can be deleted by calling:
* http://example.com/zerobin/?pasteid=<pasteid>&deletetoken=<deletetoken>
* http://example.com/privatebin/?pasteid=<pasteid>&deletetoken=<deletetoken>
*
* @access public
* @return string

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22

@ -1,21 +1,21 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22
*/
/**
* zerobin
* privatebin
*
* Controller, puts it all together.
*/
class zerobin
class privatebin
{
/**
* version
@ -106,7 +106,7 @@ class zerobin
/**
* constructor
*
* initializes and runs ZeroBin
* initializes and runs PrivateBin
*
* @access public
* @return void
@ -115,7 +115,7 @@ class zerobin
{
if (version_compare(PHP_VERSION, '5.2.6') < 0)
{
throw new Exception(i18n::_('ZeroBin requires php 5.2.6 or above to work. Sorry.'), 1);
throw new Exception(i18n::_('PrivateBin requires php 5.2.6 or above to work. Sorry.'), 1);
}
// load config from ini file
@ -156,7 +156,7 @@ class zerobin
}
/**
* initialize zerobin
* initialize privatebin
*
* @access private
* @return void
@ -388,7 +388,7 @@ class zerobin
}
/**
* Display ZeroBin frontend.
* Display PrivateBin frontend.
*
* @access private
* @return void

@ -1,35 +1,35 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22
*/
/**
* zerobin_abstract
* privatebin_abstract
*
* Abstract model for ZeroBin data access, implemented as a singleton.
* Abstract model for PrivateBin data access, implemented as a singleton.
*/
abstract class zerobin_abstract
abstract class privatebin_abstract
{
/**
* singleton instance
*
* @access protected
* @static
* @var zerobin_abstract
* @var privatebin_abstract
*/
protected static $_instance = null;
/**
* enforce singleton, disable constructor
*
* Instantiate using {@link getInstance()}, zerobin is a singleton object.
* Instantiate using {@link getInstance()}, privatebin is a singleton object.
*
* @access protected
*/
@ -38,7 +38,7 @@ abstract class zerobin_abstract
/**
* enforce singleton, disable cloning
*
* Instantiate using {@link getInstance()}, zerobin is a singleton object.
* Instantiate using {@link getInstance()}, privatebin is a singleton object.
*
* @access private
*/
@ -50,7 +50,7 @@ abstract class zerobin_abstract
* @access public
* @static
* @param array $options
* @return zerobin_abstract
* @return privatebin_abstract
*/
public static function getInstance($options) {}

@ -1,21 +1,21 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22
*/
/**
* zerobin_data
* privatebin_data
*
* Model for data access, implemented as a singleton.
*/
class zerobin_data extends zerobin_abstract
class privatebin_data extends privatebin_abstract
{
/**
* directory where data is stored
@ -32,7 +32,7 @@ class zerobin_data extends zerobin_abstract
* @access public
* @static
* @param array $options
* @return zerobin_data
* @return privatebin_data
*/
public static function getInstance($options = null)
{
@ -42,7 +42,7 @@ class zerobin_data extends zerobin_abstract
array_key_exists('dir', $options)
) self::$_dir = $options['dir'] . DIRECTORY_SEPARATOR;
// if needed initialize the singleton
if(!(self::$_instance instanceof zerobin_data)) {
if(!(self::$_instance instanceof privatebin_data)) {
self::$_instance = new self;
self::_init();
}
@ -211,7 +211,7 @@ class zerobin_data extends zerobin_abstract
}
/**
* initialize zerobin
* initialize privatebin
*
* @access private
* @static

@ -1,21 +1,21 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22
*/
/**
* zerobin_db
* privatebin_db
*
* Model for DB access, implemented as a singleton.
*/
class zerobin_db extends zerobin_abstract
class privatebin_db extends privatebin_abstract
{
/**
* cache for select queries
@ -58,12 +58,12 @@ class zerobin_db extends zerobin_abstract
* @static
* @param array $options
* @throws Exception
* @return zerobin_db
* @return privatebin_db
*/
public static function getInstance($options = null)
{
// if needed initialize the singleton
if(!(self::$_instance instanceof zerobin_db)) {
if(!(self::$_instance instanceof privatebin_db)) {
self::$_instance = new self;
}
@ -116,7 +116,7 @@ class zerobin_db extends zerobin_abstract
}
// create config table if necessary
$db_version = zerobin::VERSION;
$db_version = privatebin::VERSION;
if (!in_array(self::$_prefix . 'config', $tables))
{
self::_createConfigTable();
@ -129,7 +129,7 @@ class zerobin_db extends zerobin_abstract
}
// update database structure if necessary
if (version_compare($db_version, zerobin::VERSION, '<'))
if (version_compare($db_version, privatebin::VERSION, '<'))
{
self::_upgradeDatabase($db_version);
}
@ -588,7 +588,7 @@ class zerobin_db extends zerobin_abstract
);
self::_exec(
'INSERT INTO ' . self::$_prefix . 'config VALUES(?,?)',
array('VERSION', zerobin::VERSION)
array('VERSION', privatebin::VERSION)
);
}

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22
@ -13,12 +13,12 @@
/**
* serversalt
*
* This is a random string which is unique to each ZeroBin installation.
* This is a random string which is unique to each PrivateBin installation.
* It is automatically created if not present.
*
* Salt is used:
* - to generate unique VizHash in discussions (which are not reproductible across ZeroBin servers)
* - to generate unique deletion token (which are not re-usable across ZeroBin servers)
* - to generate unique VizHash in discussions (which are not reproductible across PrivateBin servers)
* - to generate unique deletion token (which are not re-usable across PrivateBin servers)
*/
class serversalt extends persistence
{

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22

@ -1,10 +1,10 @@
<?php
/**
* ZeroBin
* PrivateBin
*
* a zero-knowledge paste bin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:zerobin
* @link https://github.com/PrivateBin/PrivateBin
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.22

@ -3,12 +3,12 @@
* VizHash_GD
*
* Visual Hash implementation in php4+GD,
* stripped down and modified version for ZeroBin
* stripped down and modified version for PrivateBin
*
* @link http://sebsauvage.net/wiki/doku.php?id=php:vizhash_gd
* @copyright 2012 Sébastien SAUVAGE (sebsauvage.net)
* @license http://www.opensource.org/licenses/zlib-license.php The zlib/libpng License
* @version 0.0.4 beta ZeroBin 0.22
* @version 0.0.4 beta PrivateBin 0.22
*/
/**

@ -5,10 +5,10 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="robots" content="noindex" />
<title>{function="t('ZeroBin')"}</title>
<title>{function="t('PrivateBin')"}</title>
<link type="text/css" rel="stylesheet" href="css/bootstrap/bootstrap-3.3.5.css" />
<link type="text/css" rel="stylesheet" href="css/bootstrap/bootstrap-theme-3.3.5.css" />
<link type="text/css" rel="stylesheet" href="css/bootstrap/zerobin.css?{$VERSION|rawurlencode}" />{if="$SYNTAXHIGHLIGHTING"}
<link type="text/css" rel="stylesheet" href="css/bootstrap/privatebin.css?{$VERSION|rawurlencode}" />{if="$SYNTAXHIGHLIGHTING"}
<link type="text/css" rel="stylesheet" href="css/prettify/prettify.css?{$VERSION|rawurlencode}" />{if="strlen($SYNTAXHIGHLIGHTINGTHEME)"}
<link type="text/css" rel="stylesheet" href="css/prettify/{$SYNTAXHIGHLIGHTINGTHEME}.css?{$VERSION|rawurlencode}" />{/if}{/if}
<script type="text/javascript" src="js/jquery-1.11.3.js"></script>
@ -19,7 +19,7 @@
<script type="text/javascript" src="js/bootstrap-3.3.5.js"></script>{if="$SYNTAXHIGHLIGHTING"}
<script type="text/javascript" src="js/prettify.js?{$VERSION|rawurlencode}"></script>{/if}{if="$MARKDOWN"}
<script type="text/javascript" src="js/showdown-1.4.1.js"></script>{/if}
<script type="text/javascript" src="js/zerobin.js?{$VERSION|rawurlencode}"></script>
<script type="text/javascript" src="js/privatebin.js?{$VERSION|rawurlencode}"></script>
<!--[if lt IE 10]>
<style type="text/css">#ienotice {display:block !important;} #oldienotice {display:block !important;}</style>
<![endif]-->
@ -39,7 +39,7 @@
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="reloadlink navbar-brand" href="/">{function="t('ZeroBin')"}</a>
<a class="reloadlink navbar-brand" href="/">{function="t('PrivateBin')"}</a>
</div>
<div id="navbar" class="navbar-collapse collapse">
<ul class="nav navbar-nav">
@ -158,8 +158,8 @@
<span class="glyphicon glyphicon-ok" aria-hidden="true"></span> {$STATUS|htmlspecialchars}
</div>{/if}
<div id="errormessage" role="alert" class="{if="!strlen($ERROR)"}hidden {/if}alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {$ERROR|htmlspecialchars}</div>
<noscript><div id="noscript" role="alert" class="nonworking alert alert-warning"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> {function="t('Javascript is required for ZeroBin to work.<br />Sorry for the inconvenience.')"}</div></noscript>
<div id="oldienotice" role="alert" class="hidden nonworking alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {function="t('ZeroBin requires a modern browser to work.')"}</div>
<noscript><div id="noscript" role="alert" class="nonworking alert alert-warning"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> {function="t('Javascript is required for PrivateBin to work.<br />Sorry for the inconvenience.')"}</div></noscript>
<div id="oldienotice" role="alert" class="hidden nonworking alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {function="t('PrivateBin requires a modern browser to work.')"}</div>
<div id="ienotice" role="alert" class="hidden alert alert-warning"><span class="glyphicon glyphicon-question-sign" aria-hidden="true"></span> {function="t('Still using Internet Explorer? Do yourself a favor, switch to a modern browser:')"}
<a href="http://www.mozilla.org/firefox/">Firefox</a>,
<a href="http://www.opera.com/">Opera</a>,
@ -198,10 +198,10 @@
</section>
<footer class="container">
<div class="row">
<h4 class="col-md-5 col-xs-8">{function="t('ZeroBin')"} <small>- {function="t('Because ignorance is bliss')"}</small></h4>
<h4 class="col-md-5 col-xs-8">{function="t('PrivateBin')"} <small>- {function="t('Because ignorance is bliss')"}</small></h4>
<p class="col-md-1 col-xs-4 text-center">{$VERSION}</p>
<p id="aboutbox" class="col-md-6 col-xs-12">
{function="t('ZeroBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://github.com/elrido/ZeroBin/wiki">project page</a>.')"}
{function="t('PrivateBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://github.com/elrido/PrivateBin/wiki">project page</a>.')"}
</p>
</div>
</footer>

@ -5,10 +5,10 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="robots" content="noindex" />
<title>{function="t('ZeroBin')"}</title>
<title>{function="t('PrivateBin')"}</title>
<link type="text/css" rel="stylesheet" href="css/bootstrap/bootstrap-theme-3.3.5.css" />
<link type="text/css" rel="stylesheet" href="css/bootstrap/darkstrap-0.9.3.css" />
<link type="text/css" rel="stylesheet" href="css/bootstrap/zerobin.css?{$VERSION|rawurlencode}" />{if="$SYNTAXHIGHLIGHTING"}
<link type="text/css" rel="stylesheet" href="css/bootstrap/privatebin.css?{$VERSION|rawurlencode}" />{if="$SYNTAXHIGHLIGHTING"}
<link type="text/css" rel="stylesheet" href="css/prettify/prettify.css?{$VERSION|rawurlencode}" />{if="strlen($SYNTAXHIGHLIGHTINGTHEME)"}
<link type="text/css" rel="stylesheet" href="css/prettify/{$SYNTAXHIGHLIGHTINGTHEME}.css?{$VERSION|rawurlencode}" />{/if}{/if}
<script type="text/javascript" src="js/jquery-1.11.3.js"></script>
@ -19,7 +19,7 @@
<script type="text/javascript" src="js/bootstrap-3.3.5.js"></script>{if="$SYNTAXHIGHLIGHTING"}
<script type="text/javascript" src="js/prettify.js?{$VERSION|rawurlencode}"></script>{/if}{if="$MARKDOWN"}
<script type="text/javascript" src="js/showdown-1.4.1.js"></script>{/if}
<script type="text/javascript" src="js/zerobin.js?{$VERSION|rawurlencode}"></script>
<script type="text/javascript" src="js/privatebin.js?{$VERSION|rawurlencode}"></script>
<!--[if lt IE 10]>
<style type="text/css">#ienotice {display:block !important;} #oldienotice {display:block !important;}</style>
<![endif]-->
@ -38,7 +38,7 @@
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="reloadlink navbar-brand" href="/">{function="t('ZeroBin')"}</a>
<a class="reloadlink navbar-brand" href="/">{function="t('PrivateBin')"}</a>
</div>
<div id="navbar" class="navbar-collapse collapse">
<ul class="nav navbar-nav">
@ -154,8 +154,8 @@
<span class="glyphicon glyphicon-ok" aria-hidden="true"></span> {$STATUS|htmlspecialchars}
</div>{/if}
<div id="errormessage" role="alert" class="{if="!strlen($ERROR)"}hidden {/if}alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {$ERROR|htmlspecialchars}</div>
<noscript><div id="noscript" role="alert" class="nonworking alert alert-error"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> {function="t('Javascript is required for ZeroBin to work.<br />Sorry for the inconvenience.')"}</div></noscript>
<div id="oldienotice" role="alert" class="hidden nonworking alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {function="t('ZeroBin requires a modern browser to work.')"}</div>
<noscript><div id="noscript" role="alert" class="nonworking alert alert-error"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> {function="t('Javascript is required for PrivateBin to work.<br />Sorry for the inconvenience.')"}</div></noscript>
<div id="oldienotice" role="alert" class="hidden nonworking alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {function="t('PrivateBin requires a modern browser to work.')"}</div>
<div id="ienotice" role="alert" class="hidden alert alert-error"><span class="glyphicon glyphicon-question-sign" aria-hidden="true"></span> {function="t('Still using Internet Explorer? Do yourself a favor, switch to a modern browser:')"}
<a href="http://www.mozilla.org/firefox/">Firefox</a>,
<a href="http://www.opera.com/">Opera</a>,
@ -194,10 +194,10 @@
</section>
<footer class="container">
<div class="row">
<h4 class="col-md-5 col-xs-8">{function="t('ZeroBin')"} <small>- {function="t('Because ignorance is bliss')"}</small></h4>
<h4 class="col-md-5 col-xs-8">{function="t('PrivateBin')"} <small>- {function="t('Because ignorance is bliss')"}</small></h4>
<p class="col-md-1 col-xs-4 text-center">{$VERSION}</p>
<p id="aboutbox" class="col-md-6 col-xs-12">
{function="t('ZeroBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://github.com/elrido/ZeroBin/wiki">project page</a>.')"}
{function="t('PrivateBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://github.com/elrido/PrivateBin/wiki">project page</a>.')"}
</p>
</div>
</footer>

@ -5,10 +5,10 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="robots" content="noindex" />
<title>{function="t('ZeroBin')"}</title>
<title>{function="t('PrivateBin')"}</title>
<link type="text/css" rel="stylesheet" href="css/bootstrap/bootstrap-theme-3.3.5.css" />
<link type="text/css" rel="stylesheet" href="css/bootstrap/darkstrap-0.9.3.css" />
<link type="text/css" rel="stylesheet" href="css/bootstrap/zerobin.css?{$VERSION|rawurlencode}" />{if="$SYNTAXHIGHLIGHTING"}
<link type="text/css" rel="stylesheet" href="css/bootstrap/privatebin.css?{$VERSION|rawurlencode}" />{if="$SYNTAXHIGHLIGHTING"}
<link type="text/css" rel="stylesheet" href="css/prettify/prettify.css?{$VERSION|rawurlencode}" />{if="strlen($SYNTAXHIGHLIGHTINGTHEME)"}
<link type="text/css" rel="stylesheet" href="css/prettify/{$SYNTAXHIGHLIGHTINGTHEME}.css?{$VERSION|rawurlencode}" />{/if}{/if}
<script type="text/javascript" src="js/jquery-1.11.3.js"></script>
@ -19,7 +19,7 @@
<script type="text/javascript" src="js/bootstrap-3.3.5.js"></script>{if="$SYNTAXHIGHLIGHTING"}
<script type="text/javascript" src="js/prettify.js?{$VERSION|rawurlencode}"></script>{/if}{if="$MARKDOWN"}
<script type="text/javascript" src="js/showdown-1.4.1.js"></script>{/if}
<script type="text/javascript" src="js/zerobin.js?{$VERSION|rawurlencode}"></script>
<script type="text/javascript" src="js/privatebin.js?{$VERSION|rawurlencode}"></script>
<!--[if lt IE 10]>
<style type="text/css">#ienotice {display:block !important;} #oldienotice {display:block !important;}</style>
<![endif]-->
@ -38,7 +38,7 @@
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="reloadlink navbar-brand" href="/">{function="t('ZeroBin')"}</a>
<a class="reloadlink navbar-brand" href="/">{function="t('PrivateBin')"}</a>
</div>
<div id="navbar" class="navbar-collapse collapse">
<ul class="nav navbar-nav">
@ -154,8 +154,8 @@
<span class="glyphicon glyphicon-ok" aria-hidden="true"></span> {$STATUS|htmlspecialchars}
</div>{/if}
<div id="errormessage" role="alert" class="{if="!strlen($ERROR)"}hidden {/if}alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {$ERROR|htmlspecialchars}</div>
<noscript><div id="noscript" role="alert" class="nonworking alert alert-error"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> {function="t('Javascript is required for ZeroBin to work.<br />Sorry for the inconvenience.')"}</div></noscript>
<div id="oldienotice" role="alert" class="hidden nonworking alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {function="t('ZeroBin requires a modern browser to work.')"}</div>
<noscript><div id="noscript" role="alert" class="nonworking alert alert-error"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> {function="t('Javascript is required for PrivateBin to work.<br />Sorry for the inconvenience.')"}</div></noscript>
<div id="oldienotice" role="alert" class="hidden nonworking alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {function="t('PrivateBin requires a modern browser to work.')"}</div>
<div id="ienotice" role="alert" class="hidden alert alert-error"><span class="glyphicon glyphicon-question-sign" aria-hidden="true"></span> {function="t('Still using Internet Explorer? Do yourself a favor, switch to a modern browser:')"}
<a href="http://www.mozilla.org/firefox/">Firefox</a>,
<a href="http://www.opera.com/">Opera</a>,
@ -194,10 +194,10 @@
</section>
<footer class="container">
<div class="row">
<h4 class="col-md-5 col-xs-8">{function="t('ZeroBin')"} <small>- {function="t('Because ignorance is bliss')"}</small></h4>
<h4 class="col-md-5 col-xs-8">{function="t('PrivateBin')"} <small>- {function="t('Because ignorance is bliss')"}</small></h4>
<p class="col-md-1 col-xs-4 text-center">{$VERSION}</p>
<p id="aboutbox" class="col-md-6 col-xs-12">
{function="t('ZeroBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://github.com/elrido/ZeroBin/wiki">project page</a>.')"}
{function="t('PrivateBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://github.com/elrido/PrivateBin/wiki">project page</a>.')"}
</p>
</div>
</footer>

@ -5,10 +5,10 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="robots" content="noindex" />
<title>{function="t('ZeroBin')"}</title>
<title>{function="t('PrivateBin')"}</title>
<link type="text/css" rel="stylesheet" href="css/bootstrap/bootstrap-3.3.5.css" />
<link type="text/css" rel="stylesheet" href="css/bootstrap/bootstrap-theme-3.3.5.css" />
<link type="text/css" rel="stylesheet" href="css/bootstrap/zerobin.css?{$VERSION|rawurlencode}" />{if="$SYNTAXHIGHLIGHTING"}
<link type="text/css" rel="stylesheet" href="css/bootstrap/privatebin.css?{$VERSION|rawurlencode}" />{if="$SYNTAXHIGHLIGHTING"}
<link type="text/css" rel="stylesheet" href="css/prettify/prettify.css?{$VERSION|rawurlencode}" />{if="strlen($SYNTAXHIGHLIGHTINGTHEME)"}
<link type="text/css" rel="stylesheet" href="css/prettify/{$SYNTAXHIGHLIGHTINGTHEME}.css?{$VERSION|rawurlencode}" />{/if}{/if}
<script type="text/javascript" src="js/jquery-1.11.3.js"></script>
@ -19,7 +19,7 @@
<script type="text/javascript" src="js/bootstrap-3.3.5.js"></script>{if="$SYNTAXHIGHLIGHTING"}
<script type="text/javascript" src="js/prettify.js?{$VERSION|rawurlencode}"></script>{/if}{if="$MARKDOWN"}
<script type="text/javascript" src="js/showdown-1.4.1.js"></script>{/if}
<script type="text/javascript" src="js/zerobin.js?{$VERSION|rawurlencode}"></script>
<script type="text/javascript" src="js/privatebin.js?{$VERSION|rawurlencode}"></script>
<!--[if lt IE 10]>
<style type="text/css">#ienotice {display:block !important;} #oldienotice {display:block !important;}</style>
<![endif]-->
@ -38,7 +38,7 @@
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="reloadlink navbar-brand" href="/">{function="t('ZeroBin')"}</a>
<a class="reloadlink navbar-brand" href="/">{function="t('PrivateBin')"}</a>
</div>
<div id="navbar" class="navbar-collapse collapse">
<ul class="nav navbar-nav">
@ -154,8 +154,8 @@
<span class="glyphicon glyphicon-ok" aria-hidden="true"></span> {$STATUS|htmlspecialchars}
</div>{/if}
<div id="errormessage" role="alert" class="{if="!strlen($ERROR)"}hidden {/if}alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {$ERROR|htmlspecialchars}</div>
<noscript><div id="noscript" role="alert" class="nonworking alert alert-warning"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> {function="t('Javascript is required for ZeroBin to work.<br />Sorry for the inconvenience.')"}</div></noscript>
<div id="oldienotice" role="alert" class="hidden nonworking alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {function="t('ZeroBin requires a modern browser to work.')"}</div>
<noscript><div id="noscript" role="alert" class="nonworking alert alert-warning"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> {function="t('Javascript is required for PrivateBin to work.<br />Sorry for the inconvenience.')"}</div></noscript>
<div id="oldienotice" role="alert" class="hidden nonworking alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {function="t('PrivateBin requires a modern browser to work.')"}</div>
<div id="ienotice" role="alert" class="hidden alert alert-warning"><span class="glyphicon glyphicon-question-sign" aria-hidden="true"></span> {function="t('Still using Internet Explorer? Do yourself a favor, switch to a modern browser:')"}
<a href="http://www.mozilla.org/firefox/">Firefox</a>,
<a href="http://www.opera.com/">Opera</a>,
@ -194,10 +194,10 @@
</section>
<footer class="container">
<div class="row">
<h4 class="col-md-5 col-xs-8">{function="t('ZeroBin')"} <small>- {function="t('Because ignorance is bliss')"}</small></h4>
<h4 class="col-md-5 col-xs-8">{function="t('PrivateBin')"} <small>- {function="t('Because ignorance is bliss')"}</small></h4>
<p class="col-md-1 col-xs-4 text-center">{$VERSION}</p>
<p id="aboutbox" class="col-md-6 col-xs-12">
{function="t('ZeroBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://github.com/elrido/ZeroBin/wiki">project page</a>.')"}
{function="t('PrivateBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://github.com/elrido/PrivateBin/wiki">project page</a>.')"}
</p>
</div>
</footer>

@ -5,10 +5,10 @@
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<meta name="robots" content="noindex" />
<title>{function="t('ZeroBin')"}</title>
<title>{function="t('PrivateBin')"}</title>
<link type="text/css" rel="stylesheet" href="css/bootstrap/bootstrap-3.3.5.css" />
<link type="text/css" rel="stylesheet" href="css/bootstrap/bootstrap-theme-3.3.5.css" />
<link type="text/css" rel="stylesheet" href="css/bootstrap/zerobin.css?{$VERSION|rawurlencode}" />{if="$SYNTAXHIGHLIGHTING"}
<link type="text/css" rel="stylesheet" href="css/bootstrap/privatebin.css?{$VERSION|rawurlencode}" />{if="$SYNTAXHIGHLIGHTING"}
<link type="text/css" rel="stylesheet" href="css/prettify/prettify.css?{$VERSION|rawurlencode}" />{if="strlen($SYNTAXHIGHLIGHTINGTHEME)"}
<link type="text/css" rel="stylesheet" href="css/prettify/{$SYNTAXHIGHLIGHTINGTHEME}.css?{$VERSION|rawurlencode}" />{/if}{/if}
<script type="text/javascript" src="js/jquery-1.11.3.js"></script>
@ -19,7 +19,7 @@
<script type="text/javascript" src="js/bootstrap-3.3.5.js"></script>{if="$SYNTAXHIGHLIGHTING"}
<script type="text/javascript" src="js/prettify.js?{$VERSION|rawurlencode}"></script>{/if}{if="$MARKDOWN"}
<script type="text/javascript" src="js/showdown-1.4.1.js"></script>{/if}
<script type="text/javascript" src="js/zerobin.js?{$VERSION|rawurlencode}"></script>
<script type="text/javascript" src="js/privatebin.js?{$VERSION|rawurlencode}"></script>
<!--[if lt IE 10]>
<style type="text/css">#ienotice {display:block !important;} #oldienotice {display:block !important;}</style>
<![endif]-->
@ -38,7 +38,7 @@
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="reloadlink navbar-brand" href="/">{function="t('ZeroBin')"}</a>
<a class="reloadlink navbar-brand" href="/">{function="t('PrivateBin')"}</a>
</div>
<div id="navbar" class="navbar-collapse collapse">
<ul class="nav navbar-nav">
@ -154,8 +154,8 @@
<span class="glyphicon glyphicon-ok" aria-hidden="true"></span> {$STATUS|htmlspecialchars}
</div>{/if}
<div id="errormessage" role="alert" class="{if="!strlen($ERROR)"}hidden {/if}alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {$ERROR|htmlspecialchars}</div>
<noscript><div id="noscript" role="alert" class="nonworking alert alert-warning"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> {function="t('Javascript is required for ZeroBin to work.<br />Sorry for the inconvenience.')"}</div></noscript>
<div id="oldienotice" role="alert" class="hidden nonworking alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {function="t('ZeroBin requires a modern browser to work.')"}</div>
<noscript><div id="noscript" role="alert" class="nonworking alert alert-warning"><span class="glyphicon glyphicon-exclamation-sign" aria-hidden="true"></span> {function="t('Javascript is required for PrivateBin to work.<br />Sorry for the inconvenience.')"}</div></noscript>
<div id="oldienotice" role="alert" class="hidden nonworking alert alert-danger"><span class="glyphicon glyphicon-alert" aria-hidden="true"></span> {function="t('PrivateBin requires a modern browser to work.')"}</div>
<div id="ienotice" role="alert" class="hidden alert alert-warning"><span class="glyphicon glyphicon-question-sign" aria-hidden="true"></span> {function="t('Still using Internet Explorer? Do yourself a favor, switch to a modern browser:')"}
<a href="http://www.mozilla.org/firefox/">Firefox</a>,
<a href="http://www.opera.com/">Opera</a>,
@ -194,10 +194,10 @@
</section>
<footer class="container">
<div class="row">
<h4 class="col-md-5 col-xs-8">{function="t('ZeroBin')"} <small>- {function="t('Because ignorance is bliss')"}</small></h4>
<h4 class="col-md-5 col-xs-8">{function="t('PrivateBin')"} <small>- {function="t('Because ignorance is bliss')"}</small></h4>
<p class="col-md-1 col-xs-4 text-center">{$VERSION}</p>
<p id="aboutbox" class="col-md-6 col-xs-12">
{function="t('ZeroBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://github.com/elrido/ZeroBin/wiki">project page</a>.')"}
{function="t('PrivateBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://github.com/elrido/PrivateBin/wiki">project page</a>.')"}
</p>
</div>
</footer>

@ -3,8 +3,8 @@
<head>
<meta charset="utf-8" />
<meta name="robots" content="noindex" />
<title>{function="t('ZeroBin')"}</title>
<link type="text/css" rel="stylesheet" href="css/zerobin.css?{$VERSION|rawurlencode}" />{if="$SYNTAXHIGHLIGHTING"}
<title>{function="t('PrivateBin')"}</title>
<link type="text/css" rel="stylesheet" href="css/privatebin.css?{$VERSION|rawurlencode}" />{if="$SYNTAXHIGHLIGHTING"}
<link type="text/css" rel="stylesheet" href="css/prettify/prettify.css?{$VERSION|rawurlencode}" />{if="strlen($SYNTAXHIGHLIGHTINGTHEME)"}
<link type="text/css" rel="stylesheet" href="css/prettify/{$SYNTAXHIGHLIGHTINGTHEME}.css?{$VERSION|rawurlencode}" />{/if}{/if}
<script type="text/javascript" src="js/jquery-1.11.3.js"></script>
@ -14,7 +14,7 @@
<script type="text/javascript" src="js/rawinflate-0.3.js"></script>{if="$SYNTAXHIGHLIGHTING"}
<script type="text/javascript" src="js/prettify.js?{$VERSION|rawurlencode}"></script>{/if}{if="$MARKDOWN"}
<script type="text/javascript" src="js/showdown-1.4.1.js"></script>{/if}
<script type="text/javascript" src="js/zerobin.js?{$VERSION|rawurlencode}"></script>
<script type="text/javascript" src="js/privatebin.js?{$VERSION|rawurlencode}"></script>
<!--[if lt IE 10]>
<style type="text/css">body {padding-left:60px;padding-right:60px;} #ienotice {display:block;} #oldienotice {display:block;}</style>
<![endif]-->
@ -27,14 +27,14 @@
<body>
<header>
<div id="aboutbox">
{function="t('ZeroBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://github.com/elrido/ZeroBin/wiki">project page</a>.')"}<br />{if="strlen($NOTICE)"}
{function="t('PrivateBin is a minimalist, open source online pastebin where the server has zero knowledge of pasted data. Data is encrypted/decrypted <i>in the browser</i> using 256 bits AES. More information on the <a href="https://github.com/elrido/PrivateBin/wiki">project page</a>.')"}<br />{if="strlen($NOTICE)"}
<span class="blink"></span> {$NOTICE}{/if}
</div>
<h1 class="title reloadlink">{function="t('ZeroBin')"}</h1><br />
<h1 class="title reloadlink">{function="t('PrivateBin')"}</h1><br />
<h2 class="title">{function="t('Because ignorance is bliss')"}</h2><br />
<h3 class="title">{$VERSION}</h3>
<noscript><div id="noscript" class="nonworking">{function="t('Javascript is required for ZeroBin to work.<br />Sorry for the inconvenience.')"}</div></noscript>
<div id="oldienotice" class="nonworking">{function="t('ZeroBin requires a modern browser to work.')"}</div>
<noscript><div id="noscript" class="nonworking">{function="t('Javascript is required for PrivateBin to work.<br />Sorry for the inconvenience.')"}</div></noscript>
<div id="oldienotice" class="nonworking">{function="t('PrivateBin requires a modern browser to work.')"}</div>
<div id="ienotice">{function="t('Still using Internet Explorer? Do yourself a favor, switch to a modern browser:')"}
<a href="http://www.mozilla.org/firefox/">Firefox</a>,
<a href="http://www.opera.com/">Opera</a>,

@ -12,5 +12,5 @@ Example for Debian and Ubuntu:
$ sudo aptitude install phpunit php5-gd php5-sqlite php5-xdebug
To run the tests, just change into this directory and run phpunit:
$ cd ZeroBin/tst
$ cd PrivateBin/tst
$ phpunit

@ -91,7 +91,7 @@ class RainTPLTest extends PHPUnit_Framework_TestCase
);
// testing version number in JS address, since other instances may not be present in different templates
$this->assertRegExp(
'#<script[^>]+src="js/zerobin.js\\?' . rawurlencode(self::$version) . '"[^>]*>#',
'#<script[^>]+src="js/privatebin.js\\?' . rawurlencode(self::$version) . '"[^>]*>#',
$this->_content,
'outputs version correctly'
);

@ -193,7 +193,7 @@ new configurationTestGenerator(array(
'attributes' => array(
'type' => 'text/css',
'rel' => 'stylesheet',
'href' => 'regexp:#css/zerobin\.css#',
'href' => 'regexp:#css/privatebin\.css#',
),
),
'$content',
@ -227,7 +227,7 @@ new configurationTestGenerator(array(
'attributes' => array(
'type' => 'text/css',
'rel' => 'stylesheet',
'href' => 'regexp:#css/zerobin.css#',
'href' => 'regexp:#css/privatebin.css#',
),
),
'$content',
@ -474,7 +474,7 @@ class configurationCombinationsTest extends PHPUnit_Framework_TestCase
/* Setup Routine */
helper::confBackup();
$this->_model = zerobin_data::getInstance(array('dir' => PATH . 'data'));
$this->_model = privatebin_data::getInstance(array('dir' => PATH . 'data'));
serversalt::setPath(PATH . 'data');
$this->reset();
}
@ -564,7 +564,7 @@ EOT;
$code .= PHP_EOL . $preString;
$code .= <<<'EOT'
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
EOT;

@ -43,7 +43,7 @@ class configurationTest extends PHPUnit_Framework_TestCase
'dir' => '../data',
),
'model' => array(
'class' => 'zerobin_data',
'class' => 'privatebin_data',
),
'model_options' => array(
'dir' => '../data',

@ -6,7 +6,7 @@ class jsonApiTest extends PHPUnit_Framework_TestCase
public function setUp()
{
/* Setup Routine */
$this->_model = zerobin_data::getInstance(array('dir' => PATH . 'data'));
$this->_model = privatebin_data::getInstance(array('dir' => PATH . 'data'));
serversalt::setPath(PATH . 'data');
$this->reset();
}
@ -42,7 +42,7 @@ class jsonApiTest extends PHPUnit_Framework_TestCase
$_SERVER['REQUEST_METHOD'] = 'POST';
$_SERVER['REMOTE_ADDR'] = '::1';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs status');
@ -76,7 +76,7 @@ class jsonApiTest extends PHPUnit_Framework_TestCase
$_SERVER['REQUEST_METHOD'] = 'PUT';
$_SERVER['REMOTE_ADDR'] = '::1';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs status');
@ -109,7 +109,7 @@ class jsonApiTest extends PHPUnit_Framework_TestCase
$_SERVER['HTTP_X_REQUESTED_WITH'] = 'JSONHttpRequest';
$_SERVER['REQUEST_METHOD'] = 'DELETE';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs status');
@ -133,7 +133,7 @@ class jsonApiTest extends PHPUnit_Framework_TestCase
$_SERVER['HTTP_X_REQUESTED_WITH'] = 'JSONHttpRequest';
$_SERVER['REQUEST_METHOD'] = 'POST';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs status');
@ -151,7 +151,7 @@ class jsonApiTest extends PHPUnit_Framework_TestCase
$_SERVER['QUERY_STRING'] = helper::getPasteId();
$_SERVER['HTTP_X_REQUESTED_WITH'] = 'JSONHttpRequest';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs success status');
@ -177,7 +177,7 @@ class jsonApiTest extends PHPUnit_Framework_TestCase
$this->_model->create(helper::getPasteId(), $paste);
$_GET['jsonld'] = 'paste';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertEquals(str_replace(
'?jsonld=',
@ -196,7 +196,7 @@ class jsonApiTest extends PHPUnit_Framework_TestCase
$this->_model->create(helper::getPasteId(), $paste);
$_GET['jsonld'] = 'comment';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertEquals(str_replace(
'?jsonld=',
@ -215,7 +215,7 @@ class jsonApiTest extends PHPUnit_Framework_TestCase
$this->_model->create(helper::getPasteId(), $paste);
$_GET['jsonld'] = 'pastemeta';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertEquals(str_replace(
'?jsonld=',
@ -234,7 +234,7 @@ class jsonApiTest extends PHPUnit_Framework_TestCase
$this->_model->create(helper::getPasteId(), $paste);
$_GET['jsonld'] = 'commentmeta';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertEquals(str_replace(
'?jsonld=',
@ -253,7 +253,7 @@ class jsonApiTest extends PHPUnit_Framework_TestCase
$this->_model->create(helper::getPasteId(), $paste);
$_GET['jsonld'] = '../cfg/conf.ini';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertEquals('{}', $content, 'does not output nasty data');
}

@ -10,7 +10,7 @@ class modelTest extends PHPUnit_Framework_TestCase
/* Setup Routine */
$options = parse_ini_file(CONF, true);
$options['model'] = array(
'class' => 'zerobin_db',
'class' => 'privatebin_db',
);
$options['model_options'] = array(
'dsn' => 'sqlite::memory:',

@ -1,5 +1,5 @@
<phpunit bootstrap="bootstrap.php" colors="true">
<testsuite name="ZeroBin Test Suite">
<testsuite name="PrivateBin Test Suite">
<directory suffix=".php">./</directory>
<exclude>configGenerator.php</exclude>
</testsuite>
@ -7,7 +7,7 @@
<whitelist>
<directory suffix=".php">../lib</directory>
<exclude>
<file>../lib/zerobin/abstract.php</file>
<file>../lib/privatebin/abstract.php</file>
</exclude>
</whitelist>
</filter>

@ -1,12 +1,12 @@
<?php
class zerobinTest extends PHPUnit_Framework_TestCase
class privatebinTest extends PHPUnit_Framework_TestCase
{
protected $_model;
public function setUp()
{
/* Setup Routine */
$this->_model = zerobin_data::getInstance(array('dir' => PATH . 'data'));
$this->_model = privatebin_data::getInstance(array('dir' => PATH . 'data'));
serversalt::setPath(PATH . 'data');
$this->reset();
}
@ -34,10 +34,10 @@ class zerobinTest extends PHPUnit_Framework_TestCase
{
$this->reset();
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertContains(
'<title>ZeroBin</title>',
'<title>PrivateBin</title>',
$content,
'outputs title correctly'
);
@ -60,10 +60,10 @@ class zerobinTest extends PHPUnit_Framework_TestCase
helper::createIniFile(CONF, $options);
$_COOKIE['lang'] = 'de';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertContains(
'<title>ZeroBin</title>',
'<title>PrivateBin</title>',
$content,
'outputs title correctly'
);
@ -82,10 +82,10 @@ class zerobinTest extends PHPUnit_Framework_TestCase
helper::createIniFile(CONF, $options);
$_COOKIE['lang'] = 'de';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertContains(
'<title>ZeroBin</title>',
'<title>PrivateBin</title>',
$content,
'outputs title correctly'
);
@ -104,7 +104,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
helper::createIniFile(CONF, $options);
$_COOKIE['lang'] = 'de';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertRegExp(
'#id="shortenbutton"[^>]*data-shortener="' . preg_quote($shortener) . '"#',
@ -125,7 +125,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
@unlink($file);
}
ob_start();
new zerobin;
new privatebin;
ob_end_clean();
foreach ($dirs as $dir) {
$file = PATH . $dir . DIRECTORY_SEPARATOR . '.htaccess';
@ -146,7 +146,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
helper::confBackup();
file_put_contents(CONF, '');
ob_start();
new zerobin;
new privatebin;
ob_end_clean();
}
@ -165,7 +165,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REQUEST_METHOD'] = 'POST';
$_SERVER['REMOTE_ADDR'] = '::1';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs status');
@ -190,7 +190,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REMOTE_ADDR'] = '::1';
trafficlimiter::canPass();
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs error status');
@ -213,7 +213,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REQUEST_METHOD'] = 'POST';
$_SERVER['REMOTE_ADDR'] = '::1';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs error status');
@ -237,7 +237,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REQUEST_METHOD'] = 'POST';
$_SERVER['REMOTE_ADDR'] = '::1';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs error status');
@ -260,7 +260,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REQUEST_METHOD'] = 'POST';
$_SERVER['REMOTE_ADDR'] = '::1';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs error status');
@ -285,7 +285,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REMOTE_ADDR'] = '::1';
$time = time();
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs status');
@ -317,7 +317,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REMOTE_ADDR'] = '::1';
$time = time();
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs status');
@ -348,7 +348,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REQUEST_METHOD'] = 'POST';
$_SERVER['REMOTE_ADDR'] = '::1';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs status');
@ -377,7 +377,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REQUEST_METHOD'] = 'POST';
$_SERVER['REMOTE_ADDR'] = '::1';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs error status');
@ -400,7 +400,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REQUEST_METHOD'] = 'POST';
$_SERVER['REMOTE_ADDR'] = '::1';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs error status');
@ -424,7 +424,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REMOTE_ADDR'] = '::1';
$this->assertFalse($this->_model->exists(helper::getPasteId()), 'paste does not exists before posting data');
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs status');
@ -457,7 +457,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REQUEST_METHOD'] = 'POST';
$_SERVER['REMOTE_ADDR'] = '::1';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs status');
@ -489,7 +489,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REMOTE_ADDR'] = '::1';
$this->_model->create(helper::getPasteId(), helper::getPaste());
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs error status');
@ -514,7 +514,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REMOTE_ADDR'] = '::1';
$this->_model->create(helper::getPasteId(), helper::getPaste());
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs status');
@ -539,7 +539,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REMOTE_ADDR'] = '::1';
$this->_model->create(helper::getPasteId(), helper::getPaste());
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs error status');
@ -565,7 +565,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$paste = helper::getPaste(array('opendiscussion' => false));
$this->_model->create(helper::getPasteId(), $paste);
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs error status');
@ -589,7 +589,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REQUEST_METHOD'] = 'POST';
$_SERVER['REMOTE_ADDR'] = '::1';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs error status');
@ -616,7 +616,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['REQUEST_METHOD'] = 'POST';
$_SERVER['REMOTE_ADDR'] = '::1';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs error status');
@ -632,7 +632,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$this->_model->create(helper::getPasteId(), helper::getPaste());
$_SERVER['QUERY_STRING'] = helper::getPasteId();
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertContains(
'<div id="cipherdata" class="hidden">' .
@ -651,7 +651,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$this->reset();
$_SERVER['QUERY_STRING'] = 'foo';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertRegExp(
'#<div[^>]*id="errormessage"[^>]*>.*Invalid paste ID\.</div>#',
@ -668,7 +668,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$this->reset();
$_SERVER['QUERY_STRING'] = helper::getPasteId();
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertRegExp(
'#<div[^>]*id="errormessage"[^>]*>.*Paste does not exist[^<]*</div>#',
@ -687,7 +687,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$this->_model->create(helper::getPasteId(), $expiredPaste);
$_SERVER['QUERY_STRING'] = helper::getPasteId();
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertRegExp(
'#<div[^>]*id="errormessage"[^>]*>.*Paste does not exist[^<]*</div>#',
@ -706,7 +706,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$this->_model->create(helper::getPasteId(), $burnPaste);
$_SERVER['QUERY_STRING'] = helper::getPasteId();
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
unset($burnPaste['meta']['salt']);
$this->assertContains(
@ -729,7 +729,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['QUERY_STRING'] = helper::getPasteId();
$_SERVER['HTTP_X_REQUESTED_WITH'] = 'JSONHttpRequest';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs success status');
@ -752,7 +752,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['QUERY_STRING'] = helper::getPasteId();
$_SERVER['HTTP_X_REQUESTED_WITH'] = 'JSONHttpRequest';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs error status');
@ -774,7 +774,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$this->_model->create(helper::getPasteId(), $oldPaste);
$_SERVER['QUERY_STRING'] = helper::getPasteId();
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$meta['formatter'] = 'syntaxhighlighting';
$this->assertContains(
@ -797,7 +797,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$this->_model->create(helper::getPasteId(), $oldPaste);
$_SERVER['QUERY_STRING'] = helper::getPasteId();
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$oldPaste['meta']['formatter'] = 'plaintext';
unset($oldPaste['meta']['salt']);
@ -822,7 +822,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_GET['pasteid'] = helper::getPasteId();
$_GET['deletetoken'] = hash_hmac('sha256', helper::getPasteId(), $paste->meta->salt);
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertRegExp(
'#<div[^>]*id="status"[^>]*>.*Paste was properly deleted[^<]*</div>#s',
@ -842,7 +842,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_GET['pasteid'] = 'foo';
$_GET['deletetoken'] = 'bar';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertRegExp(
'#<div[^>]*id="errormessage"[^>]*>.*Invalid paste ID\.</div>#',
@ -861,7 +861,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_GET['pasteid'] = helper::getPasteId();
$_GET['deletetoken'] = 'bar';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertRegExp(
'#<div[^>]*id="errormessage"[^>]*>.*Paste does not exist[^<]*</div>#',
@ -880,7 +880,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_GET['pasteid'] = helper::getPasteId();
$_GET['deletetoken'] = 'bar';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertRegExp(
'#<div[^>]*id="errormessage"[^>]*>.*Wrong deletion token[^<]*</div>#',
@ -904,7 +904,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['HTTP_X_REQUESTED_WITH'] = 'JSONHttpRequest';
$_SERVER['REQUEST_METHOD'] = 'POST';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(0, $response['status'], 'outputs status');
@ -924,7 +924,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_SERVER['HTTP_X_REQUESTED_WITH'] = 'JSONHttpRequest';
$_SERVER['REQUEST_METHOD'] = 'POST';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$response = json_decode($content, true);
$this->assertEquals(1, $response['status'], 'outputs status');
@ -944,7 +944,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_GET['pasteid'] = helper::getPasteId();
$_GET['deletetoken'] = 'does not matter in this context, but has to be set';
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertRegExp(
'#<div[^>]*id="errormessage"[^>]*>.*Paste does not exist[^<]*</div>#',
@ -967,7 +967,7 @@ class zerobinTest extends PHPUnit_Framework_TestCase
$_GET['pasteid'] = helper::getPasteId();
$_GET['deletetoken'] = hash_hmac('sha256', helper::getPasteId(), serversalt::get());
ob_start();
new zerobin;
new privatebin;
$content = ob_get_contents();
$this->assertRegExp(
'#<div[^>]*id="status"[^>]*>.*Paste was properly deleted[^<]*</div>#s',

@ -1,5 +1,5 @@
<?php
class zerobin_dataTest extends PHPUnit_Framework_TestCase
class privatebin_dataTest extends PHPUnit_Framework_TestCase
{
private $_model;
@ -8,8 +8,8 @@ class zerobin_dataTest extends PHPUnit_Framework_TestCase
public function setUp()
{
/* Setup Routine */
$this->_path = sys_get_temp_dir() . DIRECTORY_SEPARATOR . 'zerobin_data';
$this->_model = zerobin_data::getInstance(array('dir' => $this->_path));
$this->_path = sys_get_temp_dir() . DIRECTORY_SEPARATOR . 'privatebin_data';
$this->_model = privatebin_data::getInstance(array('dir' => $this->_path));
}
public function tearDown()

@ -1,5 +1,5 @@
<?php
class zerobin_dbTest extends PHPUnit_Framework_TestCase
class privatebin_dbTest extends PHPUnit_Framework_TestCase
{
private $_model;
@ -13,7 +13,7 @@ class zerobin_dbTest extends PHPUnit_Framework_TestCase
public function setUp()
{
/* Setup Routine */
$this->_model = zerobin_db::getInstance($this->_options);
$this->_model = privatebin_db::getInstance($this->_options);
}
public function testDatabaseBasedDataStoreWorks()
@ -67,7 +67,7 @@ class zerobin_dbTest extends PHPUnit_Framework_TestCase
*/
public function testGetIbmInstance()
{
zerobin_db::getInstance(array(
privatebin_db::getInstance(array(
'dsn' => 'ibm:', 'usr' => null, 'pwd' => null,
'opt' => array(PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION)
));
@ -78,7 +78,7 @@ class zerobin_dbTest extends PHPUnit_Framework_TestCase
*/
public function testGetInformixInstance()
{
zerobin_db::getInstance(array(
privatebin_db::getInstance(array(
'dsn' => 'informix:', 'usr' => null, 'pwd' => null,
'opt' => array(PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION)
));
@ -89,7 +89,7 @@ class zerobin_dbTest extends PHPUnit_Framework_TestCase
*/
public function testGetMssqlInstance()
{
zerobin_db::getInstance(array(
privatebin_db::getInstance(array(
'dsn' => 'mssql:', 'usr' => null, 'pwd' => null,
'opt' => array(PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION)
));
@ -100,7 +100,7 @@ class zerobin_dbTest extends PHPUnit_Framework_TestCase
*/
public function testGetMysqlInstance()
{
zerobin_db::getInstance(array(
privatebin_db::getInstance(array(
'dsn' => 'mysql:', 'usr' => null, 'pwd' => null,
'opt' => array(PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION)
));
@ -111,7 +111,7 @@ class zerobin_dbTest extends PHPUnit_Framework_TestCase
*/
public function testGetOciInstance()
{
zerobin_db::getInstance(array(
privatebin_db::getInstance(array(
'dsn' => 'oci:', 'usr' => null, 'pwd' => null,
'opt' => array(PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION)
));
@ -122,7 +122,7 @@ class zerobin_dbTest extends PHPUnit_Framework_TestCase
*/
public function testGetPgsqlInstance()
{
zerobin_db::getInstance(array(
privatebin_db::getInstance(array(
'dsn' => 'pgsql:', 'usr' => null, 'pwd' => null,
'opt' => array(PDO::ATTR_ERRMODE => PDO::ERRMODE_EXCEPTION)
));
@ -134,7 +134,7 @@ class zerobin_dbTest extends PHPUnit_Framework_TestCase
*/
public function testGetFooInstance()
{
zerobin_db::getInstance(array(
privatebin_db::getInstance(array(
'dsn' => 'foo:', 'usr' => null, 'pwd' => null, 'opt' => null
));
}
@ -160,7 +160,7 @@ class zerobin_dbTest extends PHPUnit_Framework_TestCase
'opendiscussion INT, ' .
'burnafterreading INT );'
);
zerobin_db::getInstance($this->_options);
privatebin_db::getInstance($this->_options);
@unlink($path);
}
}

@ -1,7 +1,7 @@
<?php
require_once 'zerobin.php';
require_once 'privatebin.php';
class zerobinWithDbTest extends zerobinTest
class privatebinWithDbTest extends privatebinTest
{
private $_options = array(
'dsn' => 'sqlite:../data/tst.sq3',
@ -16,7 +16,7 @@ class zerobinWithDbTest extends zerobinTest
public function setUp()
{
/* Setup Routine */
$this->_model = zerobin_db::getInstance($this->_options);
$this->_model = privatebin_db::getInstance($this->_options);
serversalt::setPath(PATH . 'data');
$this->reset();
}
@ -34,7 +34,7 @@ class zerobinWithDbTest extends zerobinTest
// but then inject a db config
$options = parse_ini_file(CONF, true);
$options['model'] = array(
'class' => 'zerobin_db',
'class' => 'privatebin_db',
);
$options['model_options'] = $this->_options;
helper::confBackup();

@ -37,7 +37,7 @@ limit = 0
dir = "../data"
[model]
class = "zerobin_db"
class = "privatebin_db"
[model_options]
dsn = "sqlite:../data/db.sq3"

Loading…
Cancel
Save