Issue Implementing Ads with Vungle

I’m trying to implement ads on Unity for my program with Vungle, I followed the implementation guide at

https://support.vungle.com/hc/en-us/articles/360003455452#reference-sample-app-0-3

But the ads aren’t displaying at all. I get a debug.log that seems to indicate the ad was called, but no ad displays, even if I build and run the program. I contacted support, but they haven’t been super helpful. They told me to wait a little longer before calling the ad, I put it on a coroutine with a 10 second delay and still no ad. Here’s my script for reference,

using System.Collections; using System.Collections.Generic; using UnityEngine;

public class VungleAds : MonoBehaviour { string appID; string iosAppID = "ios_app_id"; string androidAppID = "android_app_id"; string windowsAppID = "5fbfc6bc1136b9069f63f0bf";

void Awake() { appID = windowsAppID; Vungle.init(appID); }

private void Start() {     StartCoroutine(ShowBanner());     Vungle.loadBanner(appID, Vungle.VungleBannerSize.VungleAdSizeBanner, Vungle.VungleBannerPosition.BottomCenter); }  IEnumerator ShowBanner() {      yield return new WaitForSeconds(3);     if (Vungle.isAdvertAvailable(appID))     {         Vungle.showBanner(appID);     }     else     {         print("No ad");         StartCoroutine(ShowBanner());     } } 

}

It’s just printing "No ad." repeatedly.

Does anyone have any experience with Vungle ads? I have been trying to figure this out for like a week haha.

Thanks

Does this registry entry for implementing custom protocol handlers in Windows present a security risk?

Background

Some features are not yet available on the web platform and thus require cooperation with a native application in order to provide them. One method for a web application and a native application to communicate with each other is a custom protocol handler.

For instance, the web application can call "mycustomproto://some/params", where "mycustomproto" must first be registered with the operating system as a valid URI protocol. On Windows, this is done in the registry. There are a few keys/subkeys/values etc that must be added to the registry, but only one actually deals with specifying the executable and it’s parameter(s).

Note that once the protocol handler is registered with the operating system, it can be launched by any website that knows of its existence, subjecting it to potential abuse.


Example Windows registry value for this purpose

All of the examples that I’ve found documenting this show the following:

C:\myapp.exe "%1"


Primary Question

Assuming that the registered handler (e.g. "myapp.exe") has zero possible security flaws, is the above example registry value sufficient for ensuring that malicious websites are unable to piggyback additional commands and/or arguments?


Clarifications

  • For the purpose of this question, please assume that the protocol handler (e.g. "myapp.exe") is incapable of exposing vulnerabilities of its own – it’s idle – it launches, does nothing, and quits. This question is specifically related to the browser and/or OS and the "execution" of this registry value.
  • Can malicious actors somehow escape out of the "%1" double quotes and cause the browser and/or OS to run additional commands (e.g. && C:\Win32\do-something-malicious.example.exe)?
  • Similarly, can malicious actors somehow send additional arguments to the protocol handler? Or does the "%1" ensure that the handler will only ever receive a single argument?
  • If this registry value is insufficient to only ever call the protocol handler (and nothing more) with a single argument, is there a better way?

Question about implementing Singletons

Just came upon programming patterns and learned about singleton. I’m on the process of creating my first game and it contains several managers (see attached).I wanted to implement singleton on each of the managers,but the only way I can think is copy pasting the singleton pattern on each awake method script attached to each manager. Question would be, is there a more efficient way to do it rather than pasting the pattern on each awake method?

enter image description here

Learning about Exploitation using VMs. What vulnerabilities should I be implementing? [closed]

Recently, I’ve been working on a project to learn a little bit about the exploitation of vulnerable systems (kind of like vulnhub). Problem is, I want to do it DIY (learn more about configuration / setup this way), but I don’t really know what vulnerabilities to implement on a "victim" Debian machine that I will "attack" with Kali Linux (all in VMs at the moment).

What I’m looking for: Vulnerabilities that are seen commonly in real-world production environments. Misconfigurations or bugs in common programs / operating systems. I want to simulate something realistic — not too vulnerable yet still vulnerable enough to exploit and learn something. That’s not necessarily to say that Remote Code Exec and Priv Esc are unwanted; I just want to limit the number of those kinds of vulns to make my attack paths more interesting.

In other words, what general kinds of exploits or programs (OpenSMTPD, PHP stuff, etc.) that have historically been pretty vulnerable are there that I can install / configure onto my vulnerability lab and play around with? If applicable, a corresponding CVE would be really helpful too. Shoot me with your recommendations.

Implementing Queue operations in $\Theta(1)$

We want to implement a Queue which has two special operations besides the regular Queue operations: $ getMiddle$ (returns the element from the middle of the Queue, for example, if the Queue has 7 elements, it returns the 4th element, if the Queue has 6 elements, it returns the 3rd or the 4th) and $ popMiddle$ (removes the middle element). We want both of these operations and all the other Queue operations to run in $ \theta(1)$ . Pick a suitable data structure for representing the Queue, implement the $ popMiddle$ , pop and push operations and explain in short how the other operations would be implemented.

I was thinking that the linked list would be a good pick if we keep in mind also the tail. But there is a problem when popping the middle because we have to iterate until there. An array would not be good because when erasnig we have to move all the elements to the left, if not there is no suitable formula to find the middle. Does somebody have better ideas?

How do i produce keypairs for my users while implementing json web token

I want to check the integrity of my user information; that the information which my website server receives was indeed sent by them. From what I understand, json web tokens (jwt) is the way to go.

I want to use asymmetric keys for the signing. I know that key pairs can be generated using these commands:

openssl genrsa -out private.pem 2048 openssl rsa -in private.pem -outform PEM -pubout -out public.pem 

But how do I produce key pairs from javascript code for my users when they sign in. And how do I store the private key at the user end and the public key at the server end ?

Finding the timestamps of processes implementing Lamport’s clocks

I have been asked this question, but don’t know how to go about answering it.

Three process, which are implementing Lamport’s clocks, are running and a lot of events are taking, place including some messages being sent between the processes. The arrows and circles represent in-processor events and messages being sent between process. Assume all clocks starts on 0 and the time goes from left to right. Provide the logical timestamps associated with each event.

image

To my understadning each circle will mean +1 increase in the proccess clock and the arrows means that it should add the time from where the process is from +1 to the process which receives the arrow. Is this a correct understanding of the task or am I missing something?

Implementing an efficent priority queue using only stacks

Is it possible to implement an efficient priority queue (as efficient as a heap) only using the stack data structure?

The usual efficiency for a priority queue which is implemented using a heap is :

  • get min – $ O(1)$
  • extract min – $ O(\log n)$
  • add – $ O(\log n)$

Would it be possible to do something with the same complexity using only stacks?

Implementing Kramers Kronig Relation in Mathematica for Reflection Spectrum

I’m new to Mathematica and I have to solve this problem but all of my approaches are wrong 🙁 So, please can anyone help me with this equation? Here it is: enter image description here

Here is my data : https://pastebin.com/preM342D The data is in ln(sqrt(R)), w And here is my code:

   {R, w} = ToExpression@Import["https://pastebin.com/raw/preM342D"]; f = Interpolation[Transpose[{Flatten[w], Flatten[R]}]] theta[w_] :=   theta[w] =    2 w/Pi NIntegrate[ f[a]/(a^2 - w^2), {a, 0, 3.2},       Method -> "PrincipalValue", Exclusions -> {(a^2 - w^2) == 0}] //     Quiet DiscretePlot[theta[w], {w, 0.5, 3.5, .25}, AxesOrigin -> {0, 0},   Joined -> True] 

P.S. I know that this question was discussed before, but all the answers that were given I can’t get to work. Very appreciate for any help