pointing to /dev/null
added: DbBase::AssertValueBin(PGresult * r, int row, int col, std::string & result)
it reads binary (bytea) data
added: DbTextStream can handle 'bool' types now
(is puts 'true' of 'false' to the stream)
changed: now passwords can be stored either as plain text, a hash or can be encrypted
with RSA
currently we have following hashes:
md4, md5, sha1, sha224, sha256, sha384, sha512
we are using openssl to manage them
(look at config options for more info)
changed: winix version to 0.4.7
added: class Run - you can run any program from os and send a buffer to its standard input
and read what the program put on its standard output
added: class Crypt (in System) - calculating hashes, and crypting/decrypting
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@734 e52654a7-88a9-db11-a3e9-0013d4bc506e
we have there two pointers:
Request * request;
Session * session;
these are the current request and the current session
the session GC was moved to SessionManager (was in SessionContainer)
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@708 e52654a7-88a9-db11-a3e9-0013d4bc506e
added winix functions: ln
winix function 'default' can be used without redirecting now
added new tickets types: TypeProgress, TypeString, TypeMultistring, TypeImages, TypeFiles
now tickets are combined with files
added winix functions: showtickets
fixed mountpoints:
when the default root mount was created its parameter table was empty
and it caused accessing to a non-existing objects
fixed logger:
modifiers (log1, log2, log3) were incorrectly treated
added modifier: log4 (debug info)
now we are moving threads to a new plugin 'thread'
created directory: plugins/thread
(not finished yet)
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@704 e52654a7-88a9-db11-a3e9-0013d4bc506e
- we have a class BaseThread -- this is a base class -- we can inherit from it when
creating a new thread
- others treads are correctly stopped (when signal comes) -- pthread_join
- we have a special thread only for signals
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@685 e52654a7-88a9-db11-a3e9-0013d4bc506e
changed: sessions are deleted at the end of a request (and only a few sessions)
other sessions will be deleted after a next request
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@684 e52654a7-88a9-db11-a3e9-0013d4bc506e
changed: functions for text/numbers conversions
int Toi(const std::string & str, int base = 10);
int Toi(const std::wstring & str, int base = 10);
int Toi(const char * str, int base = 10);
int Toi(const wchar_t * str, int base = 10);
long Tol(const std::string & str, int base = 10);
long Tol(const std::wstring & str, int base = 10);
long Tol(const char * str, int base = 10);
long Tol(const wchar_t * str, int base = 10);
template<class CharType>
bool Toa(unsigned long value, CharType * buffer, size_t buf_len, int base = 10);
template<class CharType>
bool Toa(long value, CharType * buffer, size_t buf_len, int base = 10);
template<class CharType>
bool Toa(unsigned int value, CharType * buffer, size_t buf_len, int base = 10);
template<class CharType>
bool Toa(int value, CharType * buffer, size_t buf_len, int base = 10);
const wchar_t * Toa(unsigned int value, int base = 10);
const wchar_t * Toa(unsigned long value, int base = 10);
const wchar_t * Toa(int value, int base = 10);
const wchar_t * Toa(long value, int base = 10);
void Toa(int value, std::string & res, int base = 10, bool clear = true);
void Toa(long value, std::string & res, int base = 10, bool clear = true);
void Toa(int value, std::wstring & res, int base = 10, bool clear = true);
void Toa(long value, std::wstring & res, int base = 10, bool clear = true);
added: HtmlTextStream class (files htmltextstream.cpp htmltextstream.h in templates)
this is a special stream for automatically escaping html tags
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@682 e52654a7-88a9-db11-a3e9-0013d4bc506e
fixed: when winix exits the session data were not properly destroyed (memory leak)
we should set request.session pointer to each session when deleting sessions
from session_container
the session data were not properly destroyed when winix checked for
outdated sessions (and when it was removing them)
fixed: performance (memcpy used too often)
in some places there were reserve method used (on std::wstring/std::string objects)
especially in AssignString() method and TextStream<> object
if we add a new string we should check the new size
and only call reserve() if the new size will be greater than existing one
(plus some constant)
changed: fcgi objects moved to App class (from Request)
now we use thread safe methods (e.g. FCGX_Accept_r)
added: log_plugin_call option to the config
default: false
when true winix log when a plugin function is called
added: winix parameter 'nostat' for not calculating statistics
(useful when making performance tests)
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@680 e52654a7-88a9-db11-a3e9-0013d4bc506e
so sometimes the time of the dir was changed
now for converting tm into time_t use:
time_t Time(const tm & par);
time_t Time(const tm * par);
tm Time(time_t par);
from core/misc.h
now winix internally use GMT time
only when printing it is converted to local user time
temporarily all users use the same local time (config: time_zone_offset)
(only logs are genereted with local system time)
added to system:
time_t LocalTime(time_t gmt_time);
tm LocalTime(const tm * ptm);
tm LocalTime(const tm & ptm);
they convert GMT time to local user time
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@666 e52654a7-88a9-db11-a3e9-0013d4bc506e
columns: dir_id, param, value
we are able to build complicated tickets
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@664 e52654a7-88a9-db11-a3e9-0013d4bc506e
but with a Clear() method
the dynamic allocated buffer can be easily reused
added: DbTextStream a special version of a stream
used to create a database string query
everything is escaped by default
added: DbBase a base class with some basic methods for communicating
with the database
added: DbConn a class for managing connection to the database
changed: some refactoring in Db class
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@655 e52654a7-88a9-db11-a3e9-0013d4bc506e
mount type and mount fs are of type 'int' now
they can be added by plugins
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@652 e52654a7-88a9-db11-a3e9-0013d4bc506e
(now we have O(1) time for selecting the right html template)
added: winix function: template
for selecting a template for an item (file or dir)
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@636 e52654a7-88a9-db11-a3e9-0013d4bc506e
they are in FunThread and FunTicket classes now
added funtion FunUptime (I forgot about it)
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@631 e52654a7-88a9-db11-a3e9-0013d4bc506e
now we have app object and singletons are only: log logn plugin and app
git-svn-id: svn://ttmath.org/publicrep/winix/trunk@628 e52654a7-88a9-db11-a3e9-0013d4bc506e