Apple (iOS/Mac OSX)

People say tabloid hacks are always looking for an angle. This time, they'd be right: Tilting disk of proto-planets spotted

The Register - Tue, 01/15/2019 - 03:06
Only 45 parsecs away if you fancy a look up close

Astronomers have found the first example of a protoplanetary disk forming at a right angle to its parent stars, according to a paper published in Nature Astronomy this week.…

Forget Finding Nemo: This AI can identify a single zebrafish out of a 100-strong shoal

The Register - Tue, 01/15/2019 - 02:01
Sounds fishy, yet it works for fruit flies, too. So take that, fish/fly-spotting humans

AI systems excel in pattern recognition, so much so that they can stalk individual zebrafish and fruit flies even when the animals are in groups of up to a hundred.…

Want to get rich from bug bounties? You're better off exterminating roaches for a living

The Register - Tue, 01/15/2019 - 00:54
Before you outsource security to strangers, try boosting internal cybersecurity skills

Security researchers looking to earn a living as bug bounty hunters would to do better to pursue actual insects.…

On Apple’s $29 iPhone Battery Replacement Program and Its Role in Their Earnings Miss

Daring Fireball - Mon, 01/14/2019 - 23:30

Jean-Louis Gassée, on Apple’s earnings warning:

I have a hard time believing that the $29 limited time offer had a significant impact on Apple’s numbers. Did Apple replace hundreds of thousands of batteries? I doubt it. At 100 replacements per Apple Store times 500 stores, that’s 50K happy customers and only $50M in missed new iPhone revenues. I’d have to be off by a factor of 10 — half a million iPhone battery upgrades, one thousand repairs per Apple Store — to approach a mere $500M in missed revenue.

[Update: My battery upgrade discussion above is wrong in two ways.

  1. As readers pointed out, my numbers estimate might be too low.

  2. And… the error might not matter. Apple had full knowledge of battery replacement numbers when issuing its Nov 1st guidance.]

I’m pretty sure Gassée’s back-of-the-envelope estimate of the number of batteries replaced was way too low. During Apple’s all-hands meeting January 3, Tim Cook said Apple replaced 11 million batteries under the $29 replacement program, and they’d have only anticipated about 1-2 million battery replacements normally. (The fact that Cook held this all-hands meeting was reported by Mark Gurman at Bloomberg, but the contents of the meeting haven’t leaked. Well, except for this nugget I’m sharing here.)

But Gassée’s second point still stands: the battery replacement program ran all year long, so even if it was more popular than Apple originally expected, why wasn’t it accounted for in guidance issued on November 1 — 10 months after the program started? My guess: the effect of the battery replacement program on new iPhone sales wasn’t apparent until after the iPhone XR and XS models were available. A few million extra iPhone users happy with the performance of their old iPhones with new batteries — who would have otherwise upgraded to a new iPhone this year — put a ding in the bottom line.

Categories: Apple (iOS/Mac OSX)

Epyc move: Supermicro plunges into Cascade Lake’s Optanical waters

The Register - Mon, 01/14/2019 - 23:03
Silicon Valley box slinger clams it's first on the block with Intel processor... which isn't out yet

In brief Supermicro is touting what's said to be the "first to market" Intel Cascade Lake AP Xeon server – and it's fitted with Optane DIMM modules to make in-memory apps, particularly the AI ones, run faster.…

Oh, SSH, IT please see this: Malicious servers can fsck with your PC's files during scp slurps

The Register - Mon, 01/14/2019 - 20:44
Data transfer tools caught not checking what exactly they're downloading

A decades-old oversight in the design of Secure Copy Protocol (SCP) tools can be exploited by malicious servers to unexpectedly alter victims' files on their client machines, it has emerged.…

The Vitamin D Myth

Daring Fireball - Mon, 01/14/2019 - 20:17

Rowan Jacobsen, writing for Outside:

In November, one of the largest and most rigorous trials of the vitamin ever conducted — in which 25,871 participants received high doses for five years — found no impact on cancer, heart disease, or stroke.

How did we get it so wrong? How could people with low vitamin D levels clearly suffer higher rates of so many diseases and yet not be helped by supplementation?

As it turns out, a rogue band of researchers has had an explanation all along. And if they’re right, it means that once again we have been epically misled.

These rebels argue that what made the people with high vitamin D levels so healthy was not the vitamin itself. That was just a marker. Their vitamin D levels were high because they were getting plenty of exposure to the thing that was really responsible for their good health — that big orange ball shining down from above.

The oldest mistake in the book: conflating cause and effect.

Categories: Apple (iOS/Mac OSX)

This must be some kind of mistake. IT managers axed, CEO and others' wallets lightened in patient hack aftermath

The Register - Mon, 01/14/2019 - 18:45
Executives held to account? And three underlings thanked for their work? What is this madness?

The Singaporean government-owned biz responsible for that country's patient database has fined senior executives, including the CEO, and dismissed two managers, after blunders allowed hackers to siphon off private records.…

How can I unit test this recursive repeat logic that uses Timers?

iOS Programming - Mon, 01/14/2019 - 18:19

I'm trying to figure out the best way to unit test this "repeatThis" method below. It's not production code, but it mimics my production code I'm trying to test...

- (void)repeatThis:(NSInteger)repeatCount { if (repeatCount > 0) { NSTimer *timer = self.timers[identifier]; if (timer) { [timer invalidate]; } timer = [NSTimer scheduledTimerWithTimeInterval:10 repeats:NO block:^(NSTimer *_Nonnull timer) { [self repeatThis:repeatCount - 1]; }]; self.timers[identifier] = timer; } }

I'd like to write the test in Swift, and test the repeat logic, but I keep running into roadblocks. Ideas?

submitted by /u/BishopOfBattle
[link] [comments]

Need to refactor my project to MVC/MVVM. What code do I move and where?

iOS Programming - Mon, 01/14/2019 - 18:03

I've been getting pretty acquainted with iOS development and have been working on this one simple project for my company for a couple of months. I recently completed the front end and we brought in another friend who's a software engineer professionally to help us with developing the backend. He's taken a look at the app and given his feedback.

One of his suggestions to me was to refactor my code to MVC or MVVM. I've looked into these and know the purpose of them, and my project has text fields, buttons, table views, picker views, and other functions all in the view controller classes (5 total). My only real question is what do I move where? I have arrays that have data to be loaded into the tables and pickers, and IBOutlets for all the different components and IBActions for the buttons.

I just need guidance on where things should be moved around to (depending which design pattern I follow of course). Any help or resources to look at would be greatly appreciated!

submitted by /u/chicity_kid
[link] [comments]

A billion-dollar question: What was really behind Qualcomm's surprise ten-digit gift to Apple?

The Register - Mon, 01/14/2019 - 18:00
Is the chip company an abusive monopolist – or tough negotiator?

The chip industry's strong-arm tactics have been laid bare this month in the anti-trust legal battle brought by America's Federal Trade Commission (FTC) against Qualcomm.…

Cops told: No, you can't have a warrant to force a big bunch of people to unlock their phones by fingerprint, face scans

The Register - Mon, 01/14/2019 - 17:46
Judge rules compelled use of biometrics runs into Fifth Amendment protections

A US judge last week denied police a warrant to unlock a number of devices using biometrics identifiers like fingerprints and faces, extending more privacy to device owners than previous recent cases.…

what are the performance implications for changing UIView properties?

iOS Programming - Mon, 01/14/2019 - 17:44

I am building an app where I have some kind of parallax effect with hundreds of views doing things in response to a scale event

At first I thought that CALayer would be a better approach here for performance reasons. I stopped doing that because I could not find anything that would allow me to animate properties of the layers and scrub through them based on scale progress.

For UIView there is the UIViewPropertyAnimators which worked fine at first. I also couldn't find any reliable information about performance differences between UIView and CAShapeLayer

Now I have the problem that the UIViewPropertyAnimators can not run in parallel. Simply creating multiple causes an enormous performance degradation for some reason.

I get constant 55+ fps when i change the views alpha & frame origin with the same UIViewPropertyAnimators

This is reduced to 35 fps (on iphone X btw) when I use two animators in parallel, one for alpha and one for origin

Now I have the following more concrete questions and hope that someone can help me with that, It appears to be very hard to google this, perhaps because it's so trivial?

  • if I change a UIViews property like frame.origin and alpha myself, can I spam it? Is there a transaction system I have to use to commit multiple changes at once?

  • If so, could this be the problem that causes multiple UIViewPropertyAnimators to degrade in performance? Any other idea?

  • Any performant third party library that you can recommend that supports scrubbing of animations and defining multiple animations (for different timing curves) in parallel?

  • If not, where would I start reading about implementing this myself? I'm not afraid to get my hands dirty but I can't seem to find the right entry point

  • If I implement myself, are UIViews the way to go? Should I go with CAShapeLayer instead? Both is possible for my use case

submitted by /u/learnjava
[link] [comments]

Intel's Software Guard caught asleep at its post: Patch out now for SGX give-me-admin hole

The Register - Mon, 01/14/2019 - 16:41
Chipzilla adds to IT admins security update load

While admins were busy wrangling with the mass of security patches from Microsoft, Adobe, and SAP last week, Intel slipped out a fix for a potentially serious flaw in its Software Guard Extensions (SGX) feature.…

Scheduling a new notification when old notification is received

iOS Programming - Mon, 01/14/2019 - 16:03


So I'm trying to schedule a new notification when the old notification is received. My current setup is that when the app is open, the user can create an alarm with nagging. What I want to achieve is the following:

App creates notification at given date/time with repeating set to false. When the push notification is received in the "didReceive" method in the AppDelegate, I want to schedule a new notification with a repeating interval of 60 seconds.

My code looks like the following:

func userNotificationCenter(_ center: UNUserNotificationCenter, didReceive response: UNNotificationResponse, withCompletionHandler completionHandler: @escaping () -> Void) { UNUserNotificationCenter.current().requestAuthorization(options: [.alert, .badge, .sound]) { (granted, error) in print("granted: (\(granted)") } let content = UNMutableNotificationContent() content.title = NSString.localizedUserNotificationString(forKey: "Hi", arguments: nil) content.body = NSString.localizedUserNotificationString(forKey: "Test", arguments: nil) let trigger = UNTimeIntervalNotificationTrigger(timeInterval: TimeInterval(60), repeats: true) let request = UNNotificationRequest(identifier: "TEST_ID_NAG", content: content, trigger: trigger) UNUserNotificationCenter.current().add(request) { (error) in if error == nil { print("Notification request added.") } } completionHandler() }

The notification does not get scheduled. I've also enabled push notifications and the background modes "Background fetch" and "Remote notification (for later)" if that matters.

Could anyone help me out by pointing me to the right direction? I'm trying to suspect that this isn't even possible.

Thanks in advance!

submitted by /u/apachino
[link] [comments]

Sorry for the cheep shot: Bird legal eagles fire DMCA takedown at scooter unlock blog

The Register - Mon, 01/14/2019 - 15:40
EFF slams bad eggs for trying to censor instructions on to unlock gizmos from app

Bird has apologized for sending a legal threat to a blogger who outlined how its scooters-for-hire – those electric gizmos littering city streets – can have their motherboards replaced to unlock them from their app, and driven away.…

Facebook's pay-for-more-eyeballs shtick looks too good to be true: Page views, Likes from 'fake' profiles

The Register - Mon, 01/14/2019 - 15:18
Small biz raises doubts over value of social network's ad tech

Analysis Imagine a store where you go in, pay money, and sometimes leave empty-handed. That's digital advertising in a nutshell because it's full of fraud.…