Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8429303
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 10, 20262026-06-10T05:17:53+00:00 2026-06-10T05:17:53+00:00

I had found this free source code in http://www.broccoliproducts.com/softnotebook/desblowfish/BlowFishCrytography.cs When I imported it in

  • 0

I had found this free source code in http://www.broccoliproducts.com/softnotebook/desblowfish/BlowFishCrytography.cs

When I imported it in my project, it gave me some error about

The name ‘_assertBufferMatch’ does not exist in the current context

The name ‘_assertBufferMatch’ does not exist in the current context

The name ‘Trace’ does not exist in the current context

I hadn’t modified everything, just rebuild the project, then the error occurred .

this error one is

        public static void Test()
        {

            // Declaration of local variables
            Random rnd = new Random(1);
            byte[] Key = null;
            byte[] bufferIn = null;
            byte[] bufferOut = null;
            byte[] bufferReturned = null;

            // Loop through the test vectors
            for (int iTest = 0; iTest < TestKeys.Length; iTest++)
            {

                // Load the key and plain-text
                Key = BitConverter.GetBytes(TestKeys[iTest]).Reverse().ToArray();
                bufferIn = BitConverter.GetBytes(TestPlainText[iTest]).Reverse().ToArray();

                // Encrypt with BlowFish
                BlowFishCrytography.BlowFish(bufferIn, ref bufferOut, Key, true);

                // Compare with expected result
                byte[] expectedBufferOut = BitConverter.GetBytes(TestCypherText[iTest]).Reverse().ToArray();
                _assertBufferMatch(expectedBufferOut,bufferOut);

            }

            // Loop through decrypt-encrypt tests
            for (int iTest = 0; iTest < 100*1000; iTest++)
            {

                // Dump progress
                if ((iTest % 100) == 0)
                    Trace.TraceInformation("Test {0}", iTest);

                // Load the key and plain-text
                Key = CreateBlowFishKey(rnd, MAX_KEY_BYTE_LENGTH);

                // Create a buffer of data
                int iLength = rnd.Next(1, 10*1024);
                _softCreateBuffer(ref bufferIn, iLength);
                rnd.NextBytes(bufferIn);

                // Encrypt with BlowFish
                BlowFishCrytography.BlowFishWithPadding(bufferIn, ref bufferOut, Key, true);

                // Decrypt with BlowFish
                BlowFishCrytography.BlowFishWithPadding(bufferOut, ref bufferReturned, Key, false);

                // Compare buffers
                _assertBufferMatch(bufferIn, bufferReturned);

            }

        }
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-10T05:17:55+00:00Added an answer on June 10, 2026 at 5:17 am

    That code is a unit test for the module. It seems that the test is included for Silverlight, but the _assertBufferMatch method it needs is excluded for Silverlight.

    I would just remove the method and any calls to it. It will only run in debug builds, so it won’t be necessary for the algorithm to actually work.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I had posted a question in regards to this code. I found that JTextArea
I am just starting to use pbkdf2. I've found this code here: http://crackstation.net/hashing-security.htm#phpsourcecode which
I found this question which had an answer to the question of performing batch
Has anyone else had this issue and found a working solution? I've enabled the
Somewhere here on Stack Overflow, I had found the following code some day which
I found a free program on the web that was .NET 4.0, but had
This is what I found on a algorithm/interview question book, someone else had several
I have magento installed in a subdirectory. www.domain.com/subdir/magento This site worked perfectly at one
Im doing this from my phone so feel free to edit the code for
I have an open source project which I had been actively developing JStock -

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.