HISE Logo Forum
    • Categories
    • Register
    • Login

    RSA format..

    Scheduled Pinned Locked Moved General Questions
    6 Posts 2 Posters 250 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • LindonL
      Lindon
      last edited by

      OK I have a client generating RSA keys on the server, for me to decrypt in the plug-in, and they are asking about sizes, and I cant find anything definitive in the documentation.

      So how many bits in the RSA key? - they are using .Net 7 and they cant go below 512-bit

      are we using some sort of padding too?

      HISE Development for hire.
      www.channelrobot.com

      ustkU 1 Reply Last reply Reply Quote 0
      • ustkU
        ustk @Lindon
        last edited by ustk

        @Lindon Hise creates 512bit keys:

        RSAKey::createKeyPair(publicKey, privateKey, 512, seeds, 6);
        

        Although I wonder if it would be easy to add a preference menu for longer keys.
        I have read somewhere 512bit keys have already been brute forced in a Juce made plugin...
        512 is the strict minimum for any online generator, so it might be a good idea to use a longer one, I don't see where it could be a problem to be safer

        Can't help pressing F5 in the forum...

        LindonL 1 Reply Last reply Reply Quote 0
        • ustkU
          ustk
          last edited by

          That been said, I think it is possible to replace the keys in the RSA with a longer one anyway.
          But I'm trying to create a preference entry for an "all in Hise" solution...

          Can't help pressing F5 in the forum...

          1 Reply Last reply Reply Quote 3
          • LindonL
            Lindon @ustk
            last edited by

            @ustk thanks mate.

            HISE Development for hire.
            www.channelrobot.com

            1 Reply Last reply Reply Quote 0
            • ustkU
              ustk
              last edited by ustk

              After creating a preference, I am trying to read it from the projectHandler with no success.

              void ProjectHandler::createRSAKey() const
              {
              	RSAKey publicKey;
              	RSAKey privateKey;
              
              	Random r;
              
              	const int seeds[] = { r.nextInt(), r.nextInt(), r.nextInt(), r.nextInt(), r.nextInt(), r.nextInt() };
              
              	auto existingFile = getWorkDirectory().getChildFile("RSA.xml");
              
              	if (existingFile.existsAsFile())
              	{
              		publicKey = RSAKey(getPublicKeyFromFile(existingFile));
              		privateKey = RSAKey(getPrivateKeyFromFile(existingFile));
              	}
              	else
              	{
              		//auto length = GET_HISE_SETTING(getMainController()->getSettingsObject(), HiseSettings::Other::RSAKeyLength).toString();
              		//auto length = dynamic_cast<GlobalSettingManager*>(getMainController())->getSettingsObject().getSetting(HiseSettings::Other::RSAKeyLength).toString();
              
              		auto length = GET_HISE_SETTING(getMainSynthChain(), HiseSettings::Other::RSAKeyLength).toString();
              
              		RSAKey::createKeyPair(publicKey, privateKey, (int)length, seeds, 6);
              	}
              

              I've tried a dozen of things to get the controller but I get an undeclared identifier getMainSynthChain, getProcessor or whatever I put here. I also tried some dynamic_cast but same result...

              Can't help pressing F5 in the forum...

              ustkU 1 Reply Last reply Reply Quote 0
              • ustkU
                ustk @ustk
                last edited by ustk

                @Christoph-Hart What are the serverKey1/2 used for in the RSA file? Server encrypted communication?

                Can't help pressing F5 in the forum...

                1 Reply Last reply Reply Quote 0
                • First post
                  Last post

                72

                Online

                1.7k

                Users

                11.7k

                Topics

                102.2k

                Posts