Security News
GitHub Removes Malicious Pull Requests Targeting Open Source Repositories
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
@startupjs/auth-apple
Advanced tools
yarn add @startupjs/auth-apple
yarn add @invertase/react-native-apple-authentication
В webpack.server.config.cjs -> forceCompileModules добавить:
@startupjs/auth-apple/server
В webpack.web.config.cjs -> forceCompileModules добавить:
@startupjs/auth-apple
1 - Открыть проект в xCode
2 - Targets -> Signing & Capabilities
3 - Добавить команду
4 - Дабавить Capability - Sign in with Apple
5 - Перейти в Identifiers. Там должен появиться идентификатор
6 - Перейти в Keys
7 - Создать новый ключ. Выбрать Sign in with Apple. Во вкладке Edit - выбрать нужный Primary App ID
8 - После регистрации сохранить Key ID и скачать сертификат p8
9 - Key ID закинуть в config как APPLE_KEY_ID`` 10 - Перейти в [Services IDs](https://developer.apple.com/account/resources/identifiers/list/serviceId) 11 - Зарегестрировать Service ID, с любым ID 12 - Закинуть этот ID в **config.json** как
APPLE_CLIENT_ID`
13 - Заходим в него, ставим галочку Sign In with Apple
14 - Открываем Configure
15 - Ставим нужный Primary App ID
16 - Заполняем домен и callback urls. localhost Apple не принимает, для тестов можно использовать ngrok, н-р:
https://c48c1b8bb802.ngrok.io/auth/apple/callback,
https://c48c1b8bb802.ngrok.io/auth/apple/callback-native
Импорт стратегии:
import { Strategy as AppleStrategy } from '@startupjs/auth-apple/server'
Импорт либы для конфига:
import conf from 'nconf'
В startupjsServer, в стратегии функции initAuth нужно добавить AppleStrategy, с переменными из конфига:
initAuth(ee, {
strategies: [
new AppleStrategy({
clientId: conf.get('APPLE_CLIENT_ID'),
teamId: conf.get('APPLE_TEAM_ID'),
keyId: conf.get('APPLE_KEY_ID'),
privateKeyLocation: path.join(process.cwd(), 'путь к файлу p8')
})
]
})
Для тестов можно использовать testBaseUrl
import { AuthButton as AppleAuthButton } from '@startupjs/auth-apple/client'
FAQs
Auth plugin for StartupJS auth module
The npm package @startupjs/auth-apple receives a total of 21 weekly downloads. As such, @startupjs/auth-apple popularity was classified as not popular.
We found that @startupjs/auth-apple demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 6 open source maintainers collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
GitHub removed 27 malicious pull requests attempting to inject harmful code across multiple open source repositories, in another round of low-effort attacks.
Security News
RubyGems.org has added a new "maintainer" role that allows for publishing new versions of gems. This new permission type is aimed at improving security for gem owners and the service overall.
Security News
Node.js will be enforcing stricter semver-major PR policies a month before major releases to enhance stability and ensure reliable release candidates.