|
From: <ale...@us...> - 2016-02-04 09:22:05
|
Revision: 62928
http://sourceforge.net/p/firebird/code/62928
Author: alexpeshkoff
Date: 2016-02-04 09:22:03 +0000 (Thu, 04 Feb 2016)
Log Message:
-----------
Postfix for CORE-5100: restored binary compatibility with crypt plugins for RC1
Modified Paths:
--------------
firebird/trunk/examples/dbcrypt/DbCrypt.cpp
firebird/trunk/src/include/firebird/FirebirdInterface.idl
firebird/trunk/src/include/firebird/IdlFbInterfaces.h
firebird/trunk/src/jrd/CryptoManager.cpp
Modified: firebird/trunk/examples/dbcrypt/DbCrypt.cpp
===================================================================
--- firebird/trunk/examples/dbcrypt/DbCrypt.cpp 2016-02-04 06:47:14 UTC (rev 62927)
+++ firebird/trunk/examples/dbcrypt/DbCrypt.cpp 2016-02-04 09:22:03 UTC (rev 62928)
@@ -95,8 +95,8 @@
// ICryptPlugin implementation
void encrypt(CheckStatusWrapper* status, unsigned int length, const void* from, void* to);
void decrypt(CheckStatusWrapper* status, unsigned int length, const void* from, void* to);
- void setKey(CheckStatusWrapper* status, const char* keyName,
- unsigned int length, IKeyHolderPlugin** sources);
+ void setKey(CheckStatusWrapper* status, unsigned int length, IKeyHolderPlugin** sources,
+ const char* keyName);
int release()
{
@@ -197,8 +197,8 @@
}
}
-void DbCrypt::setKey(CheckStatusWrapper* status, const char* keyName,
- unsigned int length, IKeyHolderPlugin** sources)
+void DbCrypt::setKey(CheckStatusWrapper* status, unsigned int length, IKeyHolderPlugin** sources,
+ const char* keyName)
{
status->init();
Modified: firebird/trunk/src/include/firebird/FirebirdInterface.idl
===================================================================
--- firebird/trunk/src/include/firebird/FirebirdInterface.idl 2016-02-04 06:47:14 UTC (rev 62927)
+++ firebird/trunk/src/include/firebird/FirebirdInterface.idl 2016-02-04 09:22:03 UTC (rev 62928)
@@ -724,7 +724,7 @@
// It's supposed that crypt plugin will invoke keyHandle() function from them
// to access callback interface for getting actual crypt key.
// If crypt plugin fails to find appropriate key in sources, it should raise error.
- void setKey(Status status, const string keyName, uint length, KeyHolderPlugin* sources);
+ void setKey(Status status, uint length, KeyHolderPlugin* sources, const string keyName);
void encrypt(Status status, uint length, const void* from, void* to);
void decrypt(Status status, uint length, const void* from, void* to);
}
Modified: firebird/trunk/src/include/firebird/IdlFbInterfaces.h
===================================================================
--- firebird/trunk/src/include/firebird/IdlFbInterfaces.h 2016-02-04 06:47:14 UTC (rev 62927)
+++ firebird/trunk/src/include/firebird/IdlFbInterfaces.h 2016-02-04 09:22:03 UTC (rev 62928)
@@ -2871,7 +2871,7 @@
public:
struct VTable : public IPluginBase::VTable
{
- void (CLOOP_CARG *setKey)(IDbCryptPlugin* self, IStatus* status, const char* keyName, unsigned length, IKeyHolderPlugin** sources) throw();
+ void (CLOOP_CARG *setKey)(IDbCryptPlugin* self, IStatus* status, unsigned length, IKeyHolderPlugin** sources, const char* keyName) throw();
void (CLOOP_CARG *encrypt)(IDbCryptPlugin* self, IStatus* status, unsigned length, const void* from, void* to) throw();
void (CLOOP_CARG *decrypt)(IDbCryptPlugin* self, IStatus* status, unsigned length, const void* from, void* to) throw();
};
@@ -2889,10 +2889,10 @@
public:
static const unsigned VERSION = 4;
- template <typename StatusType> void setKey(StatusType* status, const char* keyName, unsigned length, IKeyHolderPlugin** sources)
+ template <typename StatusType> void setKey(StatusType* status, unsigned length, IKeyHolderPlugin** sources, const char* keyName)
{
StatusType::clearException(status);
- static_cast<VTable*>(this->cloopVTable)->setKey(this, status, keyName, length, sources);
+ static_cast<VTable*>(this->cloopVTable)->setKey(this, status, length, sources, keyName);
StatusType::checkException(status);
}
@@ -11093,13 +11093,13 @@
this->cloopVTable = &vTable;
}
- static void CLOOP_CARG cloopsetKeyDispatcher(IDbCryptPlugin* self, IStatus* status, const char* keyName, unsigned length, IKeyHolderPlugin** sources) throw()
+ static void CLOOP_CARG cloopsetKeyDispatcher(IDbCryptPlugin* self, IStatus* status, unsigned length, IKeyHolderPlugin** sources, const char* keyName) throw()
{
StatusType status2(status);
try
{
- static_cast<Name*>(self)->Name::setKey(&status2, keyName, length, sources);
+ static_cast<Name*>(self)->Name::setKey(&status2, length, sources, keyName);
}
catch (...)
{
@@ -11199,7 +11199,7 @@
{
}
- virtual void setKey(StatusType* status, const char* keyName, unsigned length, IKeyHolderPlugin** sources) = 0;
+ virtual void setKey(StatusType* status, unsigned length, IKeyHolderPlugin** sources, const char* keyName) = 0;
virtual void encrypt(StatusType* status, unsigned length, const void* from, void* to) = 0;
virtual void decrypt(StatusType* status, unsigned length, const void* from, void* to) = 0;
};
Modified: firebird/trunk/src/jrd/CryptoManager.cpp
===================================================================
--- firebird/trunk/src/jrd/CryptoManager.cpp 2016-02-04 06:47:14 UTC (rev 62927)
+++ firebird/trunk/src/jrd/CryptoManager.cpp 2016-02-04 09:22:03 UTC (rev 62928)
@@ -1071,7 +1071,7 @@
}
FbLocalStatus st;
- crypt->setKey(&st, keyName, length, vector);
+ crypt->setKey(&st, length, vector, keyName);
st.check();
}
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|