public key – Is there any documentation for Ripple XRP signing algorithm?

I’m recently digging into the cryptocurrency Ripple (XRP). However, I found XRP leaks cryptographic explanation for how to sign a transaction.

I could get the cryptographic explanation of address encoding and the public&private key in xrpl.org. But for how to sign a transaction with private key in XRP, I’ve searched online for days but found no such reference. They are just telling me to call API to sign, and I feel hard to understand the API source code.

I want to sign an offline transaction manually, but I got stuck at what to sign. What should be signed with the private key and attached to the transaction? Is there any reference?

ssh – Find information about host/user by his public key?

Say, I was reviewing my log files and noticed that someone with certain public key tried to connect to my server and got access denied (because his public key is not in my authorized_keys file).

May I somehow gather more information about user/host with this associated public keys? For example, this key may be attached to Github profile and I can filter Github users by public keys and find the one that used to attempt to login into my server?

Thanks!

javascript – How to group an array of objects by key

What is the most efficient way to groupby objects in an array?

var allGlobalRoles = ();

                Enumerable.From(BASF.HRAutomation.HiringApproval.objJobCatalogs)
                    .Where(function (thisObj) { return thisObj.JobFamily == $("#selectJobFamily").val() && thisObj.Role == valueSelected })
                    .GroupBy('$.GlobalJob', null, function (key, g) {
                        g.ForEach(function (item) {
                            allGlobalRoles.push(item);
                        });
                    })
                    .ToArray();

result: enter image description here

i want to display the dropdown the without duplicate values.

c++ – deleting key from AVL tree that points to 1 or more values

I am working on a uni project and i need to create a idea bank that stores an idea.
Per requirements i have created an inverted index algorithm that takes all words from one idea and stores them into an AVL tree, when retrieving a word from my tree it returns the ID the word was found in.

the problem i am having is when i am deleting an idea and thus need to delete the words contained in that ID from my tree. the problem is that, whenever one word is found in two or more ideas it removes the word from all ideas.

for example
the word “Technology” can be found in idea 1 and 2
so when i traverse my tree my output would be

Key: Technology
ID: 1,2

but when i am deleting idea 1, instead of my output showing

Key Technology
ID: 2

it just shows no Ideas for that word.

here is the relevant code:

class Idea{
private:
int ID;
string content;
vector<string> keyword;
public:
int getID() {return ID;}
string getContent(){return content;}
vector<string> getKeyword(){return keyword;}

};
class IdeaBank{
private:
vector<idea>newIdea;
public:
void deleteID(int ID);
};

struct Index {
    string key;
    vector<int> idList;
};

void IdeaBank::deleteIdea(int ID)
{
    vector<string> wordsToDelete;
    vector<string>keywordsToDelete;
    Index index;
    bool del=false;
    for (int i = 0; i < newIdea.size(); i++) {
        if (ID == newIdea(i).getID()) {
            keywordsToDelete = newIdea(i).getKeyword();
            Idea idea;
            string str = newIdea(i).getContent();
            char delim = ' ';
            idea.splitKeywordsFromTxt(str, wordsToDelete, delim);
            newIdea.erase(newIdea.begin() + i);
            del = true;
        }
    }



    for (int i=0;i<keywordsToDelete.size();i++)
    {
        if (tree.AVL_Retrieve(keywordsToDelete(i),index))
        {
            for (int j=0;j<index.idList.size();j++)
            {
                if (ID == index.idList(j))
                {
                    tree.AVL_Delete(keywordsToDelete(i));
                    del = true;
                }
            }

        }

    }
    for (int i = 0; i < wordsToDelete.size(); i++) {
        if (tree.AVL_Retrieve(wordsToDelete(i),index))
        {
            for (int j=0;j<index.idList.size();j++)
            {
                if ( ID == index.idList(j))
                {
                    tree.AVL_Delete(wordsToDelete(i));
                    del = true;
                }
            }

        }

    }

    if (!del)
    cout << "Could not delete idea "<< ID<<endl;
    else
    cout << "successfully deleted idea for ID "<<ID<<endl;
}

the above function, stores every word from the selected idea into a vector and then i retrieve each word from my tree to be deleted.

My question:
when deleting a word from my tree that may return more than 1 ID, how can i only remove the ID from the ID to be deleted only.
a better example of input an output:

Idea 1:

keywords: dog

contents: i like dogs

idea 2:

keywords: dog

contents: animals

when traversing my tree my output would be

key:dog
ID: 1,2

key: i
ID:1

Key: like
ID: 1

Key: dogs
ID: 1

Key: Animals
ID: 2

when deleting ID 1
my expected output should be:
key:dog
ID: 2

Key: Animals
ID: 2

instead i get

Key: Animals
ID: 2

encryption – How can I encrypt something with a PGP private key?

I understand the normal operation is to encrypt with someone’s public key and decrypt with the private. And I’m also aware of how signatures usually work. However I’d like to ensure that in order to access the data, the recipient has actually gotten my public key and decrypted the data with it. My understanding this is possible with RSA. Is that correct that this is possible?

If so, how do I do this? And how do I then decrypt the resulting file? Ideally this is something that GPG would be able to do (tho it doesn’t look like Kleopatra on windows is able to do that that I can see).

code signing – Is SecureBoot of any use if I keep my private key in a root accessible file?

According to the Debian wiki on SecureBoot,

This removes the risk of userland malware potentially enrolling new keys and therefore bypassing the entire point of SB.

So SecureBoot stops users from installing keys without UEFI confirmation (outside of the OS) and verification with a passcode. That makes sense.

However, nothing there ever says to remove the key so root doesn’t have access to it. Does SecureBoot serve any purpose if I keep my private key in a root-accessible file?

php – Laravel 7, utilização de foreign key

Bom dia,
estou a fazer um pequeno projeto em Laravel 7 e é a primeira vez que utilizo Foreign Key e relaciono duas tabelas de Base de Dados. Em ambos os Models das respetivas tabelas já coloquei uma relação de One To One. Ao criar um produto e ao fazer salvar dá-me este erro, “General error: 1364 Field ‘id_form’ doesn’t have a default value”, o id_form é a foreign key. Tenho uma tabela de Base de Dados chamada form que tem um id, depois tenho uma tabela question que via buscar o id do form.

Para desenvolver a aplicação juntei as duas tabelas de base de dados no mesmo Controller, sendo isto o que tenho no Controller,

public function store(Request $request)
    {
        $request->validate((
            'name_form' =>'required',
            'description' => 'required',
            'email' => 'required',
            'end_date' => 'required',
            //'data_type' => 'required',
            'question' => 'required'
        ));

        $form = new Forms((
            'name_form' => $request->get('name_form'),
            'description'=> $request->get('description'),
            'email'=> $request->get('email'),
            'end_date' => $request->get('end_date')           
        ));

        $question = new Questions((
            //'data_type'=> $request->get('data_type'),
            'question'=> $request->get('question')
        ));

        $form->save();
        $question->save();

        return redirect('/backoffice/forms')->with('success', 'O formulário foi criado com sucesso.');
    }

Será que alguém me consegue ajudar para que a tabela questions vá buscar o id do form?