What technologies to use for the “front end” server to safely validate requests?

Imagine that I have a server made with technologies and programming language that are not secure for some reason, such as legacy versions with known vulnerabilities or anything else that may result in giving a hacker an opportunity to forge an invalid request to access more data or internals of the system.
Now to solve the security problem instead of rewriting the core I would like to place the 2nd server in front of it. It should have libraries to be able to accept simple HTTP requests with headers, parse/generate JSON, do the validation (to ensure it passes valid JSON to the 1st server, i.e. recursively check structure, sizes and encodings) and so be quick, simple and safe enough to make is possible to rarely update it and use any unsafe protocol for easier communication with the 1st server.
What technologies should I use for the 2nd server? What programming language?

Enemy Indicator shows both front and back

I made a simple enemy indicator which show image over the game object which look like this:

enter image description here

You can see that red exclamation mark is over the cube.

Note that Canvas is Space Screen Camera, so I had to convert screen point.

Here’s the code I’m using:

Vector2 screenPoint = mainCamera.WorldToViewportPoint(transform.position); screenPoint.x *= canvasRectTransform.sizeDelta.x; screenPoint.y *= canvasRectTransform.sizeDelta.y; screenPoint.x -= canvasRectTransform.sizeDelta.x * canvasRectTransform.pivot.x; screenPoint.y -= canvasRectTransform.sizeDelta.y * canvasRectTransform.pivot.y;  pointerRectTransform.anchoredPosition = screenPoint; 

It seems fine first time, however I noticed that when I rotate back, it shows like I’m looking at the cube in front of it:

enter image description here

You can see that image over the wall. Is there something that I missed this approach? Any advice will very appreciate it.

Using Unity 2018.3.12f1.

How does one populate an app with content when using a front end javascript framework?

For the last month or so I have been struggling with this question. One of the next logical steps in my studies of front end development is to learn how to use a JavaScript framework such as Angular or Vue.js. However, I feel blocked by this one issue that comes to mind.

How does one populate a website with content (say from a database) with a framework like Vue or Angular?

Based on my current research I have come to the conclusion that the only way to do this would be by loading the page and then using client-side JavaScript to request the relevant data after the initial load.

This, to me, seems very inefficient.

Is there any way to render the page beforehand while still keeping all the features of the frontend framework?

Relabel to front, what does topological sort according to admissible network mean?

In the CLRS book it says that “relabel to front” algorithm, which solves the maximum-flow problem, maintains a list of topologically sorted vertices in the admissible network and that vertices with zero excess flow are moved to the front of the list.

I do not fully understand what is the meaning of it. I would imagine that the vertices are sorted according to the number of admissible edges incident on it. But then how would moving vertices with no excess flow to front affects the sorting order in this case. Also how come the list is already sorted when it is initialized with random order of the vertices?

Edit:

Just realized that topological sorting of vertices in the admissible network means that for every admissible edge (u,v) in the admissible network the vertex u appears before v in the list.

This does not answer my last two parts of my question though, how is that the list is already sorted when initialized and what effect does moving zero-excess-flow vertices to front affect the order. Thanks.

2 en 1 – Problemas con if tras registrar en BD + Datos aparecen en Front End

sigo arreglando mi web deprecada, ya inserto datos en la BD con sentencias preparadas. El problema que me está surgiendo es que a pesar de que se realiza la inserción la web me lanza el if de si hubo problemas en el proceso, no se explicarme mejor, pongo código y marco ** el if.

// tras el formulario va este trozo de código  <?php else: ?> <?php  if(insertarReg($  nameValue, $  usernameValue, sha1($  passwordValue), $  emailValue)):?> <div class="container clearfix"> <h2>registro correcto</h2> <p>gracias por registrarse</p> <p>hemos enviado un email a <span style="color:brown"><?php echo $  emailValue; ?></span> para activar su cuenta. Revise su bandeja de spam.</p>  // la funcion de enviar email está en la página funciones <?php mailActivacion($  emailValue, $  username, $  url); ?> <div style="font-color: red"> <ul> <li>Name: <?php $  nameValue; ?></li> <li>Username: <?php $  usernameValue; ?></li> <li>Password: <?php $  passwordValue; ?></li> <li>Email: <?php $  emailValue; ?></li> </ul>  <?php else:  ?> <?php **if ($  respuesta == 1) ?>** <h1 style="font-color: red"> hubo un error en el proceso.</h1> 

Entiendo que debería lanzarme el pero aparece el if ($ respuesta == 1) ?> Por cierto, un notice me dice que la variable $ respuesta no está definide (undefined)

Lo mas curioso es que me muestra todos los campos de la tabla en el front end, sospecho que viene de por aquí.

    //Comprobamos si todo ha ido bien if($  name != "error" && $  username != "error" && $  password1 != "error" && $  password2 != "error" && $  email1 != "error"){    if($  existusername == "error"){ $  existeU = 1;    } if($  existEmail == "error"){ $  existeE = 1;    } if (!$  existeU && !$  existeE){ $  status = 1; } } } ?> <?php  if(!isset($  status)): ?> 

$ status me imprime los datos de los usuarios registrados en el front end. No se donde tocar, arreglar esto, ¿alguna pista? gracias.

SER sometimes requires “two clicks” to bring window to front

Hi @sven, a bug I’ve noticed since have been using SER a lot lately. In Windows 7 (possibly Windows 10 as well), SER requires “two clicks” when you have a project running and navigate away from the SER window.

To re-create the bug:

– Open SER
– Start a project (make active)
– Click to another taskbar program, for example, Excel
– Wait a while, don’t click on SER immediately after
– Click on SER icon in the taskbar
– SER doesn’t recognize the click, the window does not open
– Click SER taskbar icon again and it will show properly

This is a small but really annoying issue as when a program is clicked you would expect it to appear accordingly. It could be a Windows problem, but I’ve never encountered this with any other program besides SER.

Update: I actually just had this issue without an active project. Does SER have some sort of “sleep mode” that requires 2 clicks to re-open the window after you haven’t clicked it in the while or something?

Vista preliminar antes de cargar contenido en el front

Estoy investigando acerca de como mostrar a los usuarios la maquetacion vacia de la pagina con una leve animacion y luego cargar el contenido en cada componente, en concreto, lo que necesitaria saber es si esto tiene algun nomnbre y si como debo proceder, si solo se puede implementar usando Angular, React, Vue o investigar para implementarlo en mis webs ya sean con Angular-Laravel por ejemplo.

Este es un ejemplo de lo que busco mostrado en YouTube, tambien linkedIn lo tiene implementado.

introducir la descripción de la imagen aquí

speaker-test returns all 6 channels to front speakers

OS: KUBUNTU 19.04 Soundcard: Creative Soundblaster ZxR Sound Setup: front (left/right), center, bass, rear (left/right)

My problem is, that all speaker outputs are played at the front speakers.

I did the following:

  • Set speaker setup at Plasma sound settings to “Analog Surround 5.1-Output + Analog Stereo-Input”
  • If I click on any rear speaker there, to test audio output, they are played on front speakers. The setup seems very faulty:
    • rear right: output on front left and right at the same time
    • rear left: output on front left and right at the same time
    • center: output on front left and right at the same time
    • front left: output on front left (one of two correct speakers)
    • front right: output on front right (one of two correct speakers)
  • I then executed alsamixer and noticed that my NVIDIA Graphics card was initially selected. I switched with F6 to my ZxR and set it up like this: enter image description here
  • I ran speaker-test -Dplug:surround51 -c6 -twav. An error message appeared and I was unable to perform the command: Error when opening the device: -2
  • I googled how to set the default device and so I did cat /proc/asound/cards:
 0 [NVidia         ]: HDA-Intel - HDA NVidia                       HDA NVidia at 0xdf080000 irq 17  1 [Creative       ]: HDA-Intel - HDA Creative                       HDA Creative at 0xdf204000 irq 19 

with kate ~/.asoundrc I set my default device:

defaults.pcm.card 1 defaults.ctl.card 1 defaults.timer.card 1 
  • after a restart speaker-test -Dplug:surround51 -c6 -twav was working: Unfortunately rear left output is on front left, rear right output is on front right, center appears to be on both front (left/right) speakers

Does anyone have any idea how I can fix this?