Mac wifi passwords are being stored in System Keychain, not iCloud Keychain

I’d like my wifi passwords to be available across my Apple devices. But my Mac is storing wifi passwords in the System Keychain, not the iCloud keychain. That means they’re not automatically shared with my iPhone.

I’ve double-checked that iCloud Keychain is turned on for my Mac. iCloud Keychain does show some wifi passwords, and recent passwords have been saved both to iCloud and System. I believe though that this is because my iPhone is saving to iCloud, so if I connect to a network with that device then iCloud Keychain will have the password.

How can I change the default Mac wifi password storage location to iCloud Keychain?

cryptography – How are extremely large integers stored and implemented in programming languages?

MPI stands for Multiple Precision Integer. Multiple precision arithmetic is what you need when you work with integer types that go beyond the machine width $w$.

The basic idea is simple, you represent a large integer with multiple fixed-width words where the i-th word is the i-th “digit” in base B where $B = 2^w$.
For example, most current machines are 64-bit so the width $w$ is 64, so with a single word you can represent unsigned integers up $2^{64}-1$. To represent integers larger than $2^{64}-1$, say a 1024-bit integer as in your RSA example, you use $lceil{1024 / 64}rceil = 16$ words $a_0, a_1, a_2, ldots, a_{15}$. Then your integer $x$ of choice is encoded as
$$
x = a_0 + 2^{64} a_1 + 2^{2*64} a_2 + ldots + 2^{15*64} a_{15}.
$$

Note that this is essentially a $1024$-bit representation, the only difference is that the bits are grouped into blocks of size 64.

Operations like additions, multiplication etcetera are implemented by building on machine addition, multiplication and so on, but of course additional work is needed to take care of carries and the like. I am not sure what the Linux kernel is using, but in the GNU/Linux world a widely used multiple precision arithmetic library is the GMP.

rest – Displaying various subsets of content stored in a database

I am looking for advice on database design for a web app I am building.

Part of the website needs to display content from a SQL database dynamically depending on the component’s context. To be more specific, I need the component to display a subset of columns from the item_info table, depending on the value in another table item_context.
I’m using Angular to build the site, and accessing the database via a REST API.
I have an idea for how to do this, but I am wondering if there is a better way.

The design I am considering is to have a table item_info that contains all the item properties, and another table that describes the display context item_context. Then use a third table what_to_display to describe which columns of item_info should be displayed. There are sufficiently large number of rows in item_context that it would not be practical to enumerate them in the application itself.
Here is an pseudocode example of the database tables:

TABLE item_info (
  item_id (primary key),
  prop_1,
  ...
  prop_n
)

TABLE item_context (
  context_id (primary key),
  what_id (foreign key what_to_display),
  ...
)

TABLE what_to_display (
  what_id (primary key),
  prop_1 Bool,  -- display if true
  ...
  prop_n Bool
)
  

With this, the REST API would discard columns from the results of querying item_info, based on the results from querying what_to_display for a given item_context.

I don’t really like that what_to_display has to have the same column names as item_info, which creates a hard-coupling in the database schema. But I can’t think of a way around that.

Is this a good design? Do you have an alternative design to suggest?

Edit

What is displayed in the component for each context is not configurable by the user, it is predefined by the admin.

MYSQL Error Code: 1442. Can’t update table in stored function/trigger because it is already used by statement which invoked

DELIMITER $$
CREATE trigger Tr_Trip_insert AFTER insert on map_vehicle_person
for each row
begin
declare master_trip_id varchar(30);
set master_trip_id = (select DATE_FORMAT(sysdate(),’%Y%m%d%h%m%s’));
IF EXISTS (select mvp.id from master_plant mp
inner join map_vehicle_person mvp on mp.id = mvp.master_plant_id where mvp.trip_id is null order by mvp.id desc limit 1)THEN
Update map_vehicle_person set trip_id = master_trip_id WHERE map_vehicle_person.ID = NEW.ID;
End IF;
END $$
DELIMITER ;

php – ¿Cómo hacer un stored procedure con el array $_GET?

Buen día, estoy realizando una página dinámica en php, que tiene en el index varios artículos, al darle clic a cualquier artículo, este, según su id, se carga en la página descripción, para obtener los datos, utiliza el siguiente código:

if(isset($_GET('id'))){
$resultado = $conexion -> query("SELECT * FROM productos WHERE IdProducto=".$_GET('id'))or die($conexion -> error);
if(mysqli_num_rows($resultado) > 0){
    $fila = mysqli_fetch_row($resultado);

Quiero hacer un Stored Procedure, pero no sé como hacerlo para que tome el valor del ID, ni como introducirlo en el query de PHP. Agradecería infinitamente si me pudiesen ayudar. Saludos.

linux – Where are packages installed from Ubuntu terminal stored in windows

Even though you can find these files in the Windows filesystem if you’re using WSL 1, you must not modify the WSL filesystem tree from Windows.

You can access these files from your Ubuntu WSL terminal. To delete the file, use the following command:

rm ~/.opam/config

If you want to access the filesystem using Windows Explorer, you can use the following syntax:

\wsl$

Only WSL instances that are currently running will appear. If the one you want doesn’t appear, launch it from Start Menu and refresh the Explorer view (eg. using F5).