Saturday, February 11, 2023

Manjaro does not boot due to kernel panic? Your Grub Customizer and oudated libcrypto.so.1.1 may be to blame

Symptoms:

Kernel panic when booting:

kernel panic - not syncing:

VFS: Unable to mount root fs on [...]

libcrypto.so.1.1 error in Grub Customizers, os-prober etc:

/etc/grub.d/bin/grubcfg_proxy: error while loading shared libraries: libcrypto.so.1.1: cannot open shared object file: No such file or directory


Solution:
  1. Start by chrooting into your Manjaro installation, from a live or current system: sudo chroot [mount point of Manjaro partiton]/HP_P5_Manjaro

  2. Mount the required file systems (only this version works, not the --bind one): mount -t proc none /proc mount -t sysfs none /sys mount -t devtmpfs none /dev mount -t tmpfs none /run

  3. (Check via df -h and mount if things work)

  4. Recreate the initramfs:
    sudo pacman -S mkinitcpio   and maybe sudo mkinitcpio -P for good measure

  5. Remove any previous installations of GRUB customizer: sudo pacman -R grub-customizer

  6. Backup the original GRUB configuration files: sudo cp -a /etc/default/grub /etc/default/grub.bak sudo cp -a /etc/grub.d /etc/grub.d.bak

  7. Remove the old GRUB configuration files: sudo rm -rf /etc/default/grub sudo rm -rf /etc/grub.d

  8. Reinstall GRUB using pacman, to recreate /etc/default/grub etc.:

  9. pacman -S grub

  10. Recreate the GRUB configuration: sudo grub-mkconfig -o /boot/grub/grub.cfg

  11. Enable os-prober in GRUB: sudo sed -i 's/^#\(GRUB_DISABLE_OS_PROBER=false\)/\1/' /etc/default/grub

  12. Update GRUB, for good measure: sudo update-grub


As code only:

sudo chroot /media/[your e.g. Ubuntu user name]/HP_P5_Manjaro
mount -t proc none /proc
mount -t sysfs none /sys
mount -t devtmpfs none /dev
mount -t tmpfs none /run
sudo pacman -R grub-customizer
sudo pacman -S mkinitcpio
sudo cp -a /etc/default/grub /etc/default/grub.bak
sudo cp -a /etc/grub.d /etc/grub.d.bak
sudo rm -rf /etc/default/grub
sudo rm -rf /etc/grub.d
pacman -S grub
sudo grub-mkconfig -o /boot/grub/grub.cfg
sudo sed -i 's/^#\(GRUB_DISABLE_OS_PROBER=false\)/\1/' /etc/default/grub
sudo update-grub



Thursday, January 23, 2020

Windows 7 sometimes safer than Windows 10: Windows CryptoAPI Spoofing Vulnerability

From the CVE-2020-0601 FAQ:


Are versions older than Windows 10 versions affected by this vulnerability?
No, only Windows 10 versions of the OS are affected. In the initial release of Windows 10 (Build 1507, TH1), Microsoft added support for ECC parameters configuring ECC curves. Prior to this, Windows only supported named ECC curves. The code which added support for ECC parameters also resulted in the certificate validation vulnerability. It was not a regression, and versions of Windows which don’t support ECC parameters configuring ECC curves (Server, 2008, Windows 7, Windows 8.1 and servers) were not affected.

(Acknowledgements: National Security Agency)


Monday, July 2, 2018

(Samsung) setup wizard has stopped - Android

This often happens when one tries to enable multiple users. Asuming that you have root, ADB, etc. try this:

Disable Samsung Setup Wizard:
pm disable com.sec.android.app.SecSetupWizard


Disable Google Setup Wizard:
pm disable com.google.android.setupwizard

Trick: you can try to install and run Titanium Backup to run it on the Android interface. 

See also StackExchange here for other method: via File Manager, etc., this one with pictures.

Samsung Galaxy Android rotation does not work, the missing com.facebook.katana is the culprit

Background: Samsung Galaxy Note, Marshmallow 6.0. After a manual OS update to prevent the Blueborne bug, and deleting most of the spying system bloatware, the screen rotation does not work anymore.

After one-by-one elimination of the system apps over a number of hours, I have found the culprit:
com.facebook.katana
that is
facebook_latest.apk

What works:
Leaving com.facebook.katana frozen using e.g. Titanium Backup.

What does not work:
* Unfreezing, running and then updating, deleting or reinstalling it
* Trying any other autorotation programs, including Xposed modules.

Alas, I could not find a better solution.

Probable underlying cause: Facebook bought Oculus and thus wants to integrate itself deep into Samsung and other devices.

As per Reverse.it, apart from the screen rotation itself, this system module allows Facebook to create a shadow phone user's profile and trace us via such hooks:

android.permission.ACCESS_COARSE_LOCATION Allows an app to access approximate location.
android.permission.WAKE_LOCK Allows using PowerManager WakeLocks to keep processor from sleeping or screen from dimming.
android.permission.VIBRATE Allows access to the vibrator.
android.permission.READ_CONTACTS Allows an application to read the user's contacts data.
android.permission.WRITE_CONTACTS Allows an application to write the user's contacts data.
android.permission.GET_ACCOUNTS Allows access to the list of accounts in the Accounts Service.
android.permission.MANAGE_ACCOUNTS -
android.permission.AUTHENTICATE_ACCOUNTS -
android.permission.READ_SYNC_SETTINGS Allows applications to read the sync settings.
android.permission.WRITE_SYNC_SETTINGS Allows applications to write the sync settings.
android.permission.ACCESS_FINE_LOCATION Allows an app to access precise location.
android.permission.BROADCAST_STICKY Allows an application to broadcast sticky intents.
com.facebook.katana.provider.ACCESS -
com.facebook.orca.provider.ACCESS -
com.facebook.pages.app.provider.ACCESS -
android.permission.DOWNLOAD_WITHOUT_NOTIFICATION -
android.permission.CAMERA Required to be able to access the camera device.
android.permission.RECORD_AUDIO Allows an application to record audio.
android.permission.WRITE_EXTERNAL_STORAGE Allows an application to write to external storage.
com.facebook.permission.prod.FB_APP_COMMUNICATION -
com.facebook.permission.prod.SYSTEM_COMMUNICATION -
android.permission.READ_PHONE_STATE Allows read only access to phone state.
android.permission.READ_CALENDAR Allows an application to read the user's calendar data.
android.permission.WRITE_CALENDAR Allows an application to write the user's calendar data.
android.permission.READ_PROFILE -
android.permission.READ_SMS Allows an application to read SMS messages.
android.permission.CHANGE_NETWORK_STATE Allows applications to change network connectivity state.
android.permission.CHANGE_WIFI_STATE Allows applications to change Wi-Fi connectivity state.
android.permission.SYSTEM_ALERT_WINDOW Allows an app to create windows using the type TYPE_SYSTEM_ALERT, shown on top of all other apps.
com.google.android.providers.gsf.permission.READ_GSERVICES -
android.permission.RECEIVE_BOOT_COMPLETED Allows an application to receive the ACTION_BOOT_COMPLETED that is broadcast after the system finishes booting.
android.permission.GET_TASKS This constant was deprecated in API level 21. No longer enforced.
android.permission.READ_EXTERNAL_STORAGE Allows an application to read from external storage.
android.permission.ACCESS_NETWORK_STATE Allows applications to access information about networks.
android.permission.REQUEST_INSTALL_PACKAGES Allows an application to request installing packages.
com.facebook.katana.permission.CROSS_PROCESS_BROADCAST_MANAGER -
android.permission.BATTERY_STATS Allows an application to collect battery statistics
android.permission.ACCESS_WIFI_STATE Allows applications to access information about Wi-Fi networks.
com.android.launcher.permission.INSTALL_SHORTCUT Allows an application to install a shortcut in Launcher.
com.facebook.receiver.permission.ACCESS -
android.permission.INTERNET Allows applications to open network sockets.
com.sec.android.provider.badge.permission.READ -
com.sec.android.provider.badge.permission.WRITE -
com.htc.launcher.permission.READ_SETTINGS -
com.htc.launcher.permission.UPDATE_SHORTCUT -
com.sonyericsson.home.permission.BROADCAST_BADGE -
com.facebook.home.permission.WRITE_BADGES -
com.google.android.c2dm.permission.RECEIVE -
com.facebook.katana.permission.C2D_MESSAGE -
com.nokia.pushnotifications.permission.RECEIVE -
com.facebook.katana.permission.RECEIVE_ADM_MESSAGE -
com.amazon.device.messaging.permission.RECEIVE -
android.permission.BIND_JOB_SERVICE -
com.google.android.gms.permission.BIND_NETWORK_TASK_SERVICE -
com.facebook.appmanager.ACCESS -

See also the source FTC vs Facebook documents here and here for further info.

-> Do you have a better solution how to get rid of Facebook for good while retaining basic usability?
Please suggest these in the comments.


Update: I have been using Dynamic Rotation instead and it does the trick without crashing, etc.

Android Samsung Galaxy - WiFi passwords not remembered

Background: Samsung Galaxy Note, Marshmallow 6.0: after a manual OS update the system does not remember WiFi passwords anymore.

What worked:
* Root the phone
* Install e.g. MiXplorer
* Go to root: /
* Click the three dots to show Options, select Show hidden
* Navigate to /system/etc/securestorage


* Find the hidden folder: .System.bin.wpa.supplicant or .System.wpa.supplicant
* Move (archive) this folder to another directory
* Reboot the phone

Added bonus: the WiFi passwords will be stored in plain text.
Short explanation why it works - see here.

What did not work:
* Manually editing wpa_supplicant.conf in /data/misc/wifi/
* Messing up with the file permissions or even deleting the whole /data/misc/wifi/
* Resetting the Network settings 
* Restoring Data.img from backup
* Trying to disable it by modyfing build.prop only
* Trying restoring via the otherwise useful WiFiConfigRestorer

Comments?

Monday, January 9, 2017

Rocksmith 2014 stopped working... BEX Error

Symptoms: Rocksmith2014 crashes some seconds into startup, with:
Rocksmith 2014 stopped working... BEX Error
Cause: BEX stands for Buffer overflow. One of the drivers (DLL files) is not compatible. 

Solutions (one of many, probably):
1. Check the size of D3DX9_42.dll file in the Rocksmith folder. If it is suspiciously small, replace it with this one (2475352 bytes in size, taken from my virgin Win7 C:\Windows\System32\ folder).
2. Reinstall Rocksmith anew.
3. Update your graphics driver.

Good luck and play it on!

Monday, December 5, 2016

Partition Magic: copy partition fails with error code 24

If using MiniTool Partition Wizard you fail to either copy or resize a partition due to "Error 24":
=========================== Welcome to Partition Wizard ========================

Loading Engine...
 
[...] 
Failed to executive [sic] this command. Running Status Error Code:24
[...]  
Running Status Error Code:24

Try this:
1. Check for the largest files on your partition using e.g. Windirstat and delete them or move to an outside storage.
2. Install and run e.g. Puran Defrag Tool, which forces defragmentation over the limits imposed by the standard Ms Windows Defrag.
3. Run Puran Defrag again and again ;)
4. Retry the copy operation with MiniTool Partition.