]> WPIA git - cassiopeia.git/commitdiff
chg: Tamper with the signature more efficiently
authorFelix Dörre <felix@dogcraft.de>
Sat, 27 Dec 2014 16:52:03 +0000 (17:52 +0100)
committerBenny Baumann <BenBE@geshi.org>
Sat, 24 Jan 2015 17:23:58 +0000 (18:23 +0100)
src/recordHandler.cpp
test/genTestData.sh

index 98991da454c08dc4a430dd9991dbb66f60540f41..7da2cda0c8d727875286e2cb6100809ac9f66004 100644 (file)
@@ -62,11 +62,8 @@ public:
     }
 
     void work() {
-        std::cout << "done" << std::endl;
         std::vector<char> buffer( 2048, 0 );
-        std::cout << "reading" << std::endl;
         int res = io->read( buffer.data(), buffer.capacity() );
-        std::cout << "read" << std::endl;
 
         if( res <= 0 ) {
             parent->reset();
@@ -177,7 +174,6 @@ void DefaultRecordHandler::handle() {
         currentSession = std::shared_ptr<RecordHandlerSession>( new RecordHandlerSession( this, signer, ctx, bio ) );
     }
 
-    std::cout << "really allocated: " << currentSession << ";" << std::endl;
     currentSession->work();
 }
 
index e66735a5003ecfc980def612585578db40239fc0..87bbae6e02f3364245bbfa8e83692fe3c59818f6 100755 (executable)
@@ -5,7 +5,7 @@ fake_sigalg (){
 }
 
 fake_sig (){
-    cat $1 | sed "s/[^a]=\$/c=/" | sed "s/a=/b=/" |sed "s/c=/a=/" > $2
+    cat $1 | sed "s/[^a]...=\$/caaa=/" | sed "s/a...=/baaa=/" |sed "s/caaa=/aaaa=/" > $2
 }
 
 mkdir -p testdata