This vulnerability occurs when an app implements a custom URL scheme handler but fails to properly verify which other apps or sources are allowed to trigger it.
Modern mobile and desktop platforms use custom URL schemes (like myapp://) as a bridge for apps to communicate and pass data. However, if the receiving app doesn't enforce strict authorization checks, any malicious or untrusted app on the same device can invoke this handler. This effectively creates an unintended public interface into your app's internal functions. Without proper validation, attackers can exploit this open handler to trigger dangerous actions. For example, a vulnerable handler might allow unauthorized file deletion, data export, or changes to app settings, simply by crafting a malicious URL. The security of the entire mechanism depends entirely on the developer implementing explicit checks to verify the calling source's identity and permissions.
objective-cobjective-c
//this function will write contents to a specified file* FileObject *objectFile = [self writeToFile:[dict objectForKey: @"file"] withText:[dict objectForKey: @"text"]];} return YES;}
html// Android* @Override public boolean shouldOverrideUrlLoading(WebView view, String url){ ``` if (url.substring(0,14).equalsIgnoreCase("examplescheme:")){ if(url.substring(14,25).equalsIgnoreCase("getUserInfo")){ writeDataToView(view, UserData); return false; } else{ return true; } } }
// iOS* -(BOOL) webView:(UIWebView *)exWebView shouldStartLoadWithRequest:(NSURLRequest *)exRequest navigationType:(UIWebViewNavigationType)exNavigationType { ``` NSURL *URL = [exRequest URL]; if ([[URL scheme] isEqualToString:@"exampleScheme"]) { NSString *functionString = [URL resourceSpecifier]; if ([functionString hasPrefix:@"specialFunction"]) {
objective-cjavascript