patching a binary file

one of the kde applications I use has a small bug that has been fixed upstream but still hasn’t gotten a new build, I know the proper thing to do would be to build from source but as the fix is extremely simple I thought I’d just patch the binary with a hex editor
I’m asking for ideas and suggestions on how to patch a binary file
the app is kdeconnect-kde
https://software.opensuse.org/package/kdeconnect-kde
the patch is
https://quickgit.kde.org/?p=kdeconnect-kde.git&a=commitdiff&h=36e62891ca8062344d01c53d7dc5c91cb699690b
or simply replacing
“HostKeyAlgorithms=+ssh-dss” with “HostKeyAlgorithms=ssh-dss”; just removing the extra +
I think Okteta should be able to do it, any ideas?

Is that a string used somewhere in the program or is it a C statement?

To me it looks like a C statement. And compiling it means creating codes for the CPU like:
LOAD contents of HostKeyAlgorithms
ADD contents of ssh-dss
STORE into HostKeyAlgorithms
vs.
LOAD contents of ssh-dss
STORE into HostKeyAlgorithms
But then of course the binary values for those commands. Not easey to find in a binary executable.

I do believe it’s a command passed to an external application sshfs
I found the string in
\usr\lib64\qt5\plugins\kdeconnect\kdeconnect_sftp.so
as
HostKeyAlgorithms=+ssh-dss
48 6f 73 74 4b 65 79 41 6c 67 6f 72 69 74 68 6d 73 3d 2b 73 73 68 2d 64 73 73 20
I just don’t know what to put instead of the + (2b) maybe space (20) as (00) is a .

Hi
Just branch the package on OBS, patch, fix and submit so everyone can enjoy?
https://build.opensuse.org/package/show?project=KDE%3AExtra&package=kdeconnect-kde
[Maybe wolfi323 can do it for you?]

I did ask for an updated build here
https://bugzilla.opensuse.org/show_bug.cgi?id=954106
I got no response,
I don’t know how to use OBS I’m not a programmer but I do like to thinker.
Any way I can confirm that binary patching that file works, now dolphin can browse/edit files on my droid, if somebody wants it I can upload the patched file but a new build would be a better idea, if wolfi or another maintainer sees this a new build would be cool.

edit
I tried creating an OBS account but it said my email was already in use can I use my opensuse.org logon there?

I tried retrieving my credentials from OBS it’s the same as the forums but they don’t work there?
edit it’s the same username/password but it requires a 2nd logon
I’ll ask for an updated build from
https://build.opensuse.org/package/show?project=KDE%3AExtra&package=kdeconnect-kde

I couldn’t find a way to make a build request so I submitted a bug and asked for an updated build
https://bugzilla.opensuse.org/show_bug.cgi?id=961554

I am not a maintainer of the KDE:Unstable:Extra repo, so I cannot trigger a rebuild (which would automatically fetch the latest sources from git) there.

I do have the latest version in my repo though. AFAIK you’d need to install plasma5-session-envscript from my repo, than it should work also on an otherwise standard Leap system (i.e. you don’t have to install all the packages from my repo).

I was planning on switching to your repo again (I used it on 13.2), this is just another good reason to do so.
tanks wolfi

PS: the fix has been submitted for the stable version in KDE:Extra now too, see http://bugzilla.opensuse.org/show_bug.cgi?id=961554
It hasn’t been accepted yet though.

Sorry, I haven’t noticed that KDE:Extra has been switched to the KF5 version already, or that such a version had already been released yet.

I’ll switch my package to follow the stable package instead of unstable git snapshots then as well, and add the KDE4 version to my repo… :wink:

Ah well, the latter part is probably not necessary, the KDE4 version is still available in KDE:Extra as well.